How AI is applied across API Evangelist and APIs.io. Read my AI disclosure →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

flagsmith Environments API

Manage environments within a project. Environments represent deployment stages such as development, staging, and production.

flagsmith Environments API is one of 24 APIs that Flagsmith publishes on the APIs.io network, described by a machine-readable OpenAPI specification and an AsyncAPI event-driven specification.

Tagged areas include Environment. The published artifact set on APIs.io includes an OpenAPI specification, API documentation, an AsyncAPI specification, and an API reference.

This API exposes 61 operations across 40 paths, and defines 86 schemas. It is described by OpenAPI 3.2.0, at version 1.0.

Requests are made against a single base URL, https://api.flagsmith.com/api/v1.

61 operations 40 paths 86 schemas 8 DELETE22 GET8 PATCH18 POST5 PUT

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.2.0
API Version
1.0
Base URL
https://api.flagsmith.com/api/v1
Authentication
API Key, HTTP Bearer, HTTP Basic, API Key, API Key, HTTP Basic, API Key
Resource Areas
1

Authentication & Security 7

flagsmith Environments API declares 7 security schemes for authenticating requests. An API key is passed in the header as Authorization (apiKeyAuth). It accepts HTTP bearer tokens (Cohort_Sync_Key). It accepts HTTP basic authentication (Cohort_Sync_Key__Basic). An API key is passed in the header as X-Environment-Key (Environment_API_Key). An API key is passed in the header as Authorization (Master_API_Key). It accepts HTTP basic authentication (basicAuth). An API key is passed in the header as Authorization (tokenAuth).

  • apiKeyAuth — A secret Organisation API Token prefixed with 'Api-Key'. For example, 'Api-Key your-token-here'. This token should never be exposed in client-side code.
  • Cohort_Sync_Key — For cohort sync endpoints called by an external cohort source, such as Amplitude.
  • Cohort_Sync_Key__Basic — For cohort sync endpoints called by an external cohort source that can only send Basic credentials, such as Mixpanel. The key is the password; the username is…
  • Environment_API_Key — For SDK endpoints. Find out more .
  • Master_API_Key — For Management API endpoints. Find out more .
  • tokenAuth — Token-based authentication with required prefix "Token"

Paths & Operations 61

Across 40 paths, the API surfaces 61 operations — 8 DELETE, 22 GET, 8 PATCH, 18 POST, 5 PUT. Each is listed below with its method, path, parameters, and response codes.

Environments 61

Manage environments within a project. Environments represent deployment stages such as development, staging, and production.

GET
/environments/
List environments
listEnvironments → 200401
GET
/environments/{environment_api_key}/
Get an environment
getEnvironment 1 param → 200401404
PUT
/environments/{environment_api_key}/
Update an environment
updateEnvironment 1 param body → 200400401404
POST
/api/v1/environments/
Api v1 environments create
api_v1_environments_create body → 201
GET
/api/v1/environments/{api_key}/
Api v1 environments retrieve
api_v1_environments_retrieve 1 param → 200
PUT
/api/v1/environments/{api_key}/
Api v1 environments update
api_v1_environments_update 1 param body → 200
PATCH
/api/v1/environments/{api_key}/
Api v1 environments partial update
api_v1_environments_partial_update 1 param body → 200
DELETE
/api/v1/environments/{api_key}/
Api v1 environments destroy
api_v1_environments_destroy 1 param → 204
POST
/api/v1/environments/{api_key}/clone/
Api v1 environments clone create
api_v1_environments_clone_create 1 param body → 200
POST
/api/v1/environments/{api_key}/delete-traits/
Api v1 environments delete traits create
api_v1_environments_delete_traits_create 1 param body → 200
POST
/api/v1/environments/{api_key}/disable-v2-versioning/
Api v1 environments disable v2 versioning create
api_v1_environments_disable_v2_versioning_create 1 param → 202
GET
/api/v1/environments/{api_key}/document/
Api v1 environments document retrieve
api_v1_environments_document_retrieve 1 param → 200
POST
/api/v1/environments/{api_key}/enable-v2-versioning/
Api v1 environments enable v2 versioning create
api_v1_environments_enable_v2_versioning_create 1 param → 202
GET
/api/v1/environments/{api_key}/my-permissions/
Api v1 environments my permissions retrieve
api_v1_environments_my_permissions_retrieve 1 param → 200
GET
/api/v1/environments/{api_key}/trait-keys/
Api v1 environments trait keys retrieve
api_v1_environments_trait_keys_retrieve 1 param → 200
GET
/api/v1/environments/{api_key}/user-detailed-permissions/{user_id}/
Api v1 environments user detailed permissions retrieve
api_v1_environments_user_detailed_permissions_retrieve 2 params → 200
GET
/api/v1/environments/{environment_api_key}/api-keys/
Api v1 environments api keys list
api_v1_environments_api_keys_list 1 param → 200
POST
/api/v1/environments/{environment_api_key}/api-keys/
Api v1 environments api keys create
api_v1_environments_api_keys_create 1 param body → 201
PUT
/api/v1/environments/{environment_api_key}/api-keys/{id}/
Api v1 environments api keys update
api_v1_environments_api_keys_update 2 params body → 200
PATCH
/api/v1/environments/{environment_api_key}/api-keys/{id}/
Api v1 environments api keys partial update
api_v1_environments_api_keys_partial_update 2 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/api-keys/{id}/
Api v1 environments api keys destroy
api_v1_environments_api_keys_destroy 2 params → 204
GET
/api/v1/environments/{environment_api_key}/cohorts/
Api v1 environments cohorts list
api_v1_environments_cohorts_list 1 param → 200
POST
/api/v1/environments/{environment_api_key}/cohorts/
Api v1 environments cohorts create
api_v1_environments_cohorts_create 1 param body → 201
GET
/api/v1/environments/{environment_api_key}/cohorts/{cohort_id}/
Api v1 environments cohorts retrieve
api_v1_environments_cohorts_retrieve 2 params → 200
PATCH
/api/v1/environments/{environment_api_key}/cohorts/{cohort_id}/
Api v1 environments cohorts partial update
api_v1_environments_cohorts_partial_update 2 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/cohorts/{cohort_id}/
Api v1 environments cohorts destroy
api_v1_environments_cohorts_destroy 2 params → 202
POST
/api/v1/environments/{environment_api_key}/cohorts/{cohort_id}/sync-csv/
Api v1 environments cohorts sync csv create
api_v1_environments_cohorts_sync_csv_create 2 params body → 202400413
GET
/api/v1/environments/{environment_api_key}/cohorts/sync-keys/
Api v1 environments cohorts sync keys list
api_v1_environments_cohorts_sync_keys_list 1 param → 200
POST
/api/v1/environments/{environment_api_key}/cohorts/sync-keys/
Api v1 environments cohorts sync keys create
api_v1_environments_cohorts_sync_keys_create 1 param body → 201
DELETE
/api/v1/environments/{environment_api_key}/cohorts/sync-keys/{prefix}/
Api v1 environments cohorts sync keys destroy
api_v1_environments_cohorts_sync_keys_destroy 2 params → 204
GET
/api/v1/environments/{environment_api_key}/edge-identity-overrides
Api v1 environments edge identity overrides retrieve
api_v1_environments_edge_identity_overrides_retrieve 2 params → 200
PATCH
/api/v1/environments/{environment_api_key}/experiment-metrics/{id}/
Api v1 environments experiment metrics partial update
api_v1_environments_experiment_metrics_partial_update 2 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/experiment-metrics/{id}/
Api v1 environments experiment metrics destroy
api_v1_environments_experiment_metrics_destroy 2 params → 204
GET
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/
Api v1 environments experiments metrics list
api_v1_environments_experiments_metrics_list 2 params → 200
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/
Api v1 environments experiments metrics create
api_v1_environments_experiments_metrics_create 2 params body → 201
GET
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/{id}/
Api v1 environments experiments metrics retrieve
api_v1_environments_experiments_metrics_retrieve 3 params → 200
PUT
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/{id}/
Api v1 environments experiments metrics update
api_v1_environments_experiments_metrics_update 3 params body → 200
PATCH
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/{id}/
Api v1 environments experiments metrics partial update
api_v1_environments_experiments_metrics_partial_update 3 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/experiments/{experiment_experiment_id}/metrics/{id}/
Api v1 environments experiments metrics destroy
api_v1_environments_experiments_metrics_destroy 3 params → 204
PATCH
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/
Api v1 environments experiments partial update
api_v1_environments_experiments_partial_update 2 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/
Api v1 environments experiments destroy
api_v1_environments_experiments_destroy 2 params → 204
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/complete/
Api v1 environments experiments complete create
api_v1_environments_experiments_complete_create 2 params body → 200
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/exposures/refresh/
Api v1 environments experiments exposures refresh create
api_v1_environments_experiments_exposures_refresh_create 2 params body → 200
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/pause/
Api v1 environments experiments pause create
api_v1_environments_experiments_pause_create 2 params body → 200
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/results/refresh/
Api v1 environments experiments results refresh create
api_v1_environments_experiments_results_refresh_create 2 params body → 200
PATCH
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/rollout/
Api v1 environments experiments rollout partial update
api_v1_environments_experiments_rollout_partial_update 2 params body → 200
POST
/api/v1/environments/{environment_api_key}/experiments/{experiment_id}/start/
Api v1 environments experiments start create
api_v1_environments_experiments_start_create 2 params body → 200
GET
/api/v1/environments/{environment_api_key}/experiments/results/
Api v1 environments experiments results retrieve
api_v1_environments_experiments_results_retrieve 2 params → 200
GET
/api/v1/environments/{environment_api_key}/metrics/
Api v1 environments metrics list
api_v1_environments_metrics_list 2 params → 200
GET
/api/v1/environments/{environment_api_key}/onboarding-status/
Api v1 environments onboarding status retrieve
api_v1_environments_onboarding_status_retrieve 1 param → 200
GET
/api/v1/environments/{environment_api_key}/warehouse-connections/
Api v1 environments warehouse connections list
api_v1_environments_warehouse_connections_list 1 param → 200
POST
/api/v1/environments/{environment_api_key}/warehouse-connections/
Api v1 environments warehouse connections create
api_v1_environments_warehouse_connections_create 1 param body → 201
GET
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/
Api v1 environments warehouse connections retrieve
api_v1_environments_warehouse_connections_retrieve 2 params → 200
PUT
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/
Api v1 environments warehouse connections update
api_v1_environments_warehouse_connections_update 2 params body → 200
PATCH
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/
Api v1 environments warehouse connections partial update
api_v1_environments_warehouse_connections_partial_update 2 params body → 200
DELETE
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/
Api v1 environments warehouse connections destroy
api_v1_environments_warehouse_connections_destroy 2 params → 204
GET
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/events/
Api v1 environments warehouse connections events list
api_v1_environments_warehouse_connections_events_list 2 params → 200400503
POST
/api/v1/environments/{environment_api_key}/warehouse-connections/{connection_id}/test-warehouse-connection/
Api v1 environments warehouse connections test warehouse connection create
api_v1_environments_warehouse_connections_test_warehouse_connection_create 2 params body → 200
POST
/api/v1/environments/{environment_api_key}/warehouse-connections/test-warehouse-connection/
Api v1 environments warehouse connections test warehouse connection config…
api_v1_environments_warehouse_connections_test_warehouse_connection_config_create 1 param body → 200
GET
/api/v1/environments/get-by-uuid/{uuid}/
Api v1 environments get by uuid retrieve
api_v1_environments_get_by_uuid_retrieve 1 param → 200
GET
/api/v1/environments/permissions/
Api v1 environments permissions list
api_v1_environments_permissions_list 1 param → 200

Schemas 86

The contract defines 86 schemas that model the data the API accepts and returns. The most detailed are EnvironmentRetrieveSerializerWithMetadata (19 properties), PatchedUpdateEnvironment (18 properties), UpdateEnvironment (18 properties), EnvironmentSerializerWithMetadata (18 properties). Each schema is shown below with its type and property counts.

Environment
object
An environment in Flagsmith representing a deployment stage such as development, staging, or production.
8 properties
EnvironmentInput
object
Input object for updating an environment
4 properties 1 required
V1EnvironmentDocumentResponseExperimentMetadata
object
Represents the experiment a feature state is part of. Only present while the experiment is running.
3 properties 3 required
Group
object
2 properties 2 required
AggregationEnum
string
count - Count sum - Sum mean - Mean occurrence - Occurrence (event happened at least once)
Experiment
object
11 properties 3 required
V1EnvironmentDocumentResponseFeature
object
Represents a Flagsmith feature, defined at project level.
3 properties 3 required
V1EnvironmentDocumentResponse
object
/api/v1/environment-documents/ response. Powers Flagsmith SDK's local evaluation mode.
5 properties 5 required
ExperimentVariantResult
object
Serializer for individual variant results.
4 properties 4 required
WarehouseConnection
object
10 properties 1 required
PatchedWarehouseConnection
object
10 properties
CohortCsvSyncIgnoredRows
object
3 properties 3 required
WarehouseTypeEnum
string
flagsmith - Flagsmith snowflake - Snowflake clickhouse - ClickHouse
Metadata
object
3 properties 2 required
GetEdgeIdentityOverrides
object
1 property 1 required
EdgeMultivariateFeatureStateValue
object
2 properties 2 required
DirectionEnum
string
up - Higher is better down - Lower is better informational - Informational only
MultivariateValue
object
2 properties 2 required
CreateEnvironment
object
Mixin to add read only status to fields in a given serializer based on the existence of a subscription and a black list of plan ids Example usage: class MySeri…
18 properties 2 required
PatchedExperimentMetric
object
7 properties
PermissionModel
object
3 properties 2 required
ExperimentList
object
11 properties 2 required
V1EnvironmentDocumentResponseProject
object
Represents a Flagsmith project. For SDKs, this is mainly used to convey segment data.
1 property 1 required
V1EnvironmentDocumentResponseSegmentConditionOperatorEnum
string
GetEdgeIdentityOverridesResult
object
3 properties 3 required
TraitKeys
object
1 property 1 required
V1EnvironmentDocumentResponseSegmentRule
object
Represents a rule within a segment used by Flagsmith engine. Root rules usually contain nested rules.
3 properties 3 required
WarehouseEventNamesUnsupported
object
1 property 1 required
WarehouseConnectionStatusEnum
string
created - Created pendingconnection - Pending Connection connected - Connected errored - Errored
V1EnvironmentDocumentResponseSegment
object
Represents a Flagsmith segment. Carries rules and feature overrides.
4 properties 3 required
UserDetailedPermissions
object
4 properties 4 required
WarehouseEventNamesResult
object
2 properties 2 required
EnvironmentOnboardingStatus
object
2 properties
V1EnvironmentDocumentResponseSegmentRuleTypeEnum
string
PaginatedPermissionModelList
object
4 properties 2 required
V1EnvironmentDocumentResponseSegmentCondition
object
Represents a condition within a segment rule used by Flagsmith engine.
3 properties 3 required
DerivedFrom
object
2 properties 2 required
DetailedPermissions
object
3 properties 3 required
CloneEnvironment
object
5 properties 1 required
V1EnvironmentDocumentResponseMultivariateFeatureOption
object
Represents a single multivariate feature option in the Flagsmith UI.
1 property 1 required
FeatureValue
object
2 properties 2 required
V1EnvironmentDocumentResponseFeatureStateMetadata
object
Additional, non-evaluation data about a feature state.
1 property
FeatureValueTypeEnum
string
integer - integer string - string boolean - boolean
V1EnvironmentDocumentResponseFeatureSegment
object
Represents data specific to a segment feature override.
1 property 1 required
WarehouseEventNamesUnavailable
object
1 property 1 required
PatchedExperimentRollout
object
5 properties
Error
object
1 property 1 required
DeleteAllTraitKeys
object
1 property 1 required
ExperimentFeature
object
5 properties
CohortCsvSyncResult
object
5 properties 5 required
ExperimentAudience
object
2 properties 1 required
Cohort
object
11 properties 1 required
CohortSyncKey
object
4 properties 1 required
PatchedCohort
object
11 properties
TagBasedPermission
object
2 properties 2 required
EnvironmentMetrics
object
1 property
ExperimentStatistics
object
Serializer for statistical analysis results.
7 properties 6 required
Status7a8Enum
string
created - Created running - Running paused - Paused completed - Completed
ExperimentResults
object
Serializer for the full experiment results response.
3 properties 3 required
MatchEnum
string
any - Any all - All
V1EnvironmentDocumentResponseFeatureState
object
Used to define the state of a feature for an environment, segment overrides, and identity overrides.
7 properties 6 required
SourceTypeEnum
string
csv - CSV amplitude - Amplitude mixpanel - Mixpanel
PermissionRole
object
3 properties 2 required
V1EnvironmentDocumentResponseMultivariateFeatureStateValue
object
Represents a multivariate feature state value.
4 properties 4 required
PatchedUpdateEnvironment
object
Mixin to add read only status to fields in a given serializer based on the existence of a subscription and a black list of plan ids Example usage: class MySeri…
18 properties
PatchedEnvironmentAPIKey
object
6 properties
ExperimentMetricInline
object
2 properties 2 required
EnvironmentAPIKey
object
6 properties 1 required
CohortCsvSync
object
3 properties 1 required
PatchedMetric
object
9 properties
UpdateEnvironment
object
Mixin to add read only status to fields in a given serializer based on the existence of a subscription and a black list of plan ids Example usage: class MySeri…
18 properties 1 required
TypeD77Enum
string
STANDARD - STANDARD MULTIVARIATE - MULTIVARIATE
PaginatedEnvironmentMetricsList
object
4 properties 2 required
PatchedExperiment
object
11 properties
EnvironmentRetrieveSerializerWithMetadata
object
Functionality for serializers that need to handle metadata
19 properties 3 required
EnvironmentSerializerWithMetadata
object
Functionality for serializers that need to handle metadata
18 properties 2 required
MetricItem
object
5 properties 4 required
CohortMembershipCounts
object
3 properties 3 required
UserObjectPermissions
object
3 properties 3 required
Metric
object
9 properties 2 required
ExpectedDirectionEnum
string
increase - Increase decrease - Decrease notincrease - Should not increase notdecrease - Should not decrease
ExperimentRollout
object
5 properties 3 required
ExperimentMetric
object
7 properties 2 required
V1EnvironmentDocumentResponseIdentityOverride
object
Represents an identity override, defining feature states specific to an identity.
2 properties 2 required
BaseEdgeIdentityFeatureState
object
5 properties 1 required
WarehouseConnectionTestResult
object
2 properties 2 required

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

flagsmith-environments-api-openapi.yml Raw ↑

Other APIs Flagsmith publishes across the network.

Flagsmith Flags API
flagsmith Features API
flagsmith Identities API
flagsmith Organisations API
flagsmith Projects API
flagsmith Segments API
flagsmith Users API
flagsmith Webhooks API
Flagsmith Admin dashboard API
Flagsmith Analytics API
Flagsmith Audit API
Flagsmith Authentication API
Where this information came from

This is an independent, third-party profile of flagsmith Environments API, published by API Evangelist. We do not operate, host, resell, or support these APIs, and we are not affiliated with or endorsed by the company unless stated above. Everything here is built from publicly available information — the company's own site, developer portal, documentation, public repositories, and the specifications it publishes for public use. Nothing is obtained by breaching a system, defeating an access control, or using credentials.

The Kin Score and Agent Readiness rating are independently calculated assessments of a company's public API artifacts, scored against a published rubric. They are not certifications, endorsements, security assessments, or audits.

Corrections, re-scores, and removal are free — no partnership or purchase required, and you do not need to justify the request. A removed company is recorded as unrated, never scored zero for having asked. Acknowledgement within one business day; removal within two.

info@apievangelist.com · Read the full data-sourcing policy →
On a security or compliance team? Put security in the subject line and you will get a person, not a form — we will tell you exactly which public URLs this profile was built from.