Runtime Configuration
Manage feature flags, segments, environments, experiments, and metrics in Harness Feature Management & Experimentation (FME) with the Runtime Configuration API.
The Runtime Configuration API manages the feature flags, segments, and experiments in Harness Feature Management & Experimentation (FME). For the classic Harness Feature Flags product, use the Feature Flags API instead.
Request basics
API key token: Send a service account token or personal access token in the
x-api-keyheader. Go to Manage API keys to create one.Account, organization, and project IDs: This API names them
account_id,organization_identifier, andproject_identifier. Send all three as query parameters on every request. Go to Organizations and projects to find these identifiers.Environment ID: Endpoints that work on a single environment also take
environment_id.Base URL: Send requests to
https://app.harness.io/fme/api, followed by the endpoint path. Accounts on the US-3 cluster usehttps://app3.harness.io/fme/api.
Example request
List the feature flags in a project:
curl "https://app.harness.io/fme/api/v4/feature-flags?account_id=ACCOUNT_ID&organization_identifier=ORG_ID&project_identifier=PROJECT_ID" \
-H "x-api-key: $HARNESS_API_KEY"Replace ACCOUNT_ID, ORG_ID, and PROJECT_ID with your own values, and set HARNESS_API_KEY to your API key token.
Find an endpoint
Endpoint paths are relative to the base URL.
Feature flags: The flag itself: its name, traffic type, tags, and lifecycle. List flags with
GET /v4/feature-flags, create one withPOST /v4/feature-flags, and archive one withPOST /v4/feature-flags/{feature-flag-name}/archive. Go to Create a Feature Flag and Target Users to create a feature flag.Feature flag definitions: A flag's settings in one environment: its treatments, targeting rules, and traffic allocation. Kill, restore, and reallocate act here. Read a flag's definition in an environment with
GET /v4/feature-flag-definitions/{feature-flag-name}, change it withPATCH /v4/feature-flag-definitions/{feature-flag-name}, and kill it withPOST /v4/feature-flag-definitions/{feature-flag-name}/kill. Go to Creating, Editing, and Deleting Feature Flags to edit flag definitions through the API.Segments and segment definitions: Named lists of users or accounts you target together. List segments with
GET /v4/segments, and add keys to a segment in an environment withPOST /v4/segment-definitions/{segment-name}/keys. Go to Create a segment to create a segment.Environments: Separate copies of your flag settings, such as staging and production. List environments with
GET /v4/environmentsand create one withPOST /v4/environments. Go to Environments to manage environments.Traffic types and event types: What a flag targets, such as user or account, and the kinds of events you send to measure impact. List them with
GET /v4/traffic-typesandGET /v4/event-types. Go to Traffic Types to set up traffic types.Experiments and metrics: Tests that compare treatments, and the measures used to judge them. List experiments with
GET /v4/experimentsand metrics withGET /v4/metrics. Go to Create a Metric to create a metric.
Last updated
Was this helpful?