Download the project's configuration as a project document
const url = 'https://example.com/api/v1/projects/example/export?format=json';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://example.com/api/v1/projects/example/export?format=json' \ --header 'Authorization: Bearer <token>'Writes the project’s whole configuration as a project document, in JSON (the default, and the canonical encoding) or YAML (derived from it field for field): its environments in their order, unit types, declared attributes, segments, flags with their configuration in every environment, and experiments. A list whose order means something keeps it (a configuration’s rules, a flag’s variations, an experiment’s weights, tags); every other list and map is by key, overrides by unit type then unit identifier and prerequisites by flag, so that two exports of an unchanged project are the same bytes. Rule identifiers and rollout salts are in it, which keep every unit in its bucket in a copy; owners are email addresses, written only for an owner who holds a grant in the project and empty for any other, and an override’s note is in it and its author is not.
Members, grants, tokens, SDK keys, webhook subscriptions, change requests, audit entries, events, the standard attributes and the discovered attributes are never in it.
The ETag is an opaque tag of the project’s history, quoted: a later change to the project, whatever it touches, moves it.
Reading the project is all it takes, so nothing is audited.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The project’s key.
Query Parameters
Section titled “Query Parameters”The document’s encoding, JSON unless yaml is asked for.
Responses
Section titled “Responses”The project document, as an attachment named
{project key}-{UTC time, yyyymmddThhmmssZ}.{json|yaml}.
A project’s whole configuration, versioned apart from this API: it
has its own schema_version, a server imports every version it ever
exported, and within a version a document changes only additively
(a new optional field or section). A field it does not define is
refused naming its JSON Pointer. Identity is the key: no entity
identifier travels, except rule ids and rollout salts.
object
object
In their sort order, which the array’s order is.
object
By key.
object
By key. The standard attributes are never listed.
object
By key.
object
One comparison inside a rule or a segment. An attribute condition
names an attribute, an operator (op) and a value (none for
exists, not_exists and is_empty); in_segment and
not_in_segment name a segment; prerequisite names a flag and
one of its variations.
object
A string, number, boolean or list, as the operator needs.
By key.
object
boolean, string, number or json; never changes.
The email address of the flag’s owner.
temporary or permanent.
When a temporary flag is expected to be removed; null for a permanent one.
In the order the flag lists them, the first being the default of a flag that is not boolean.
object
JSON of the flag’s type.
The flag’s configuration in each environment, keyed by environment key.
object
object
By flag.
object
By unit type, then unit ID.
object
Why the unit has a fixed variation. Who set it does not travel.
In the order they are checked.
object
Kept across instances so that an SDK’s rule id stays stable; minted on import when absent.
One comparison inside a rule or a segment. An attribute condition
names an attribute, an operator (op) and a value (none for
exists, not_exists and is_empty); in_segment and
not_in_segment name a segment; prerequisite names a flag and
one of its variations.
object
A string, number, boolean or list, as the operator needs.
What a matching rule serves. variation serves variation; rollout
serves variation to percentage (basis points, 0 to 10,000) of the
units of unit_type, bucketed by salt; experiment serves the
experiment experiment of the flag.
object
variation, rollout or experiment.
A rollout’s salt, 16 lower-case letters and digits; it decides which units fall in the share, so it travels. Minted on import when absent.
By key, whatever their status.
object
The email address of the experiment’s owner.
The key of the flag whose variations are compared.
In the order that fixes the cumulative bucket ranges.
object
The share of the allocated traffic, in basis points.
The share of units included, in basis points.
draft, running, stopped or archived.
object
winner or removed.
Example
{ "schema_version": 1, "attributes": [ { "type": "string" } ]}The same document as YAML.
Headers
Section titled “Headers”An opaque tag of the project’s history, quoted.
invalid_request: a parameter that is malformed or out of its range, such as a cursor this API did not return.
A problem document (RFC 9457). Code-specific values are further members.
object
Stable snake_case name of the problem, which clients branch on.
An English explanation for humans; never what a client branches on.
Seconds to wait before retrying, for a rate limit.
The permission the caller lacks, for forbidden, or the role’s permission the caller lacks, for role_not_allowed.
The version the entity has now, for version_mismatch.
What still names what the write would remove or hide, for in_use.
object
What names it, such as flag, segment or experiment.
The key of the environment it is named in; null when it is named in every environment.
The slug of the auth provider to sign in through instead, for sso_required.
What keeps an auth provider from being deleted, disabled or edited, for provider_in_use, such as identities, enforced domains or only way in (the only enabled provider while local login is disabled).
Why a system the server asked did not answer as needed, for provider_unreachable; for sink_not_ready the failure class of the target’s check, such as connect or status.
The HTTP status the target answered, for sink_not_ready, when it answered.
The target’s own error code, for sink_not_ready, when it speaks one, such as a ClickHouse exception or an S3 error code.
object
JSON Pointer into the request body.
The values of the rule broken, such as the bounds of a length, for a client to explain the violation in its own language.
object
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example", "detail": "example", "request_id": "example", "retry_after": 1, "permission": "example", "current_version": 1, "references": [ { "kind": "example", "key": "example", "environment": "example" } ], "provider": "example", "used_by": [ "example" ], "failure": "example", "failure_status": 1, "failure_code": "example", "errors": [ { "pointer": "example", "code": "example", "detail": "example", "params": {} } ]}No credential, or one that is not accepted: unauthenticated without
a credential (a session cookie the server did not issue counts as
none); invalid_token, token_revoked or token_expired for an API
token, with a WWW-Authenticate header naming the code;
session_expired for a session that has ended, whose cookie is
cleared; invalid_credentials for a sign-in.
A problem document (RFC 9457). Code-specific values are further members.
object
Stable snake_case name of the problem, which clients branch on.
An English explanation for humans; never what a client branches on.
Seconds to wait before retrying, for a rate limit.
The permission the caller lacks, for forbidden, or the role’s permission the caller lacks, for role_not_allowed.
The version the entity has now, for version_mismatch.
What still names what the write would remove or hide, for in_use.
object
What names it, such as flag, segment or experiment.
The key of the environment it is named in; null when it is named in every environment.
The slug of the auth provider to sign in through instead, for sso_required.
What keeps an auth provider from being deleted, disabled or edited, for provider_in_use, such as identities, enforced domains or only way in (the only enabled provider while local login is disabled).
Why a system the server asked did not answer as needed, for provider_unreachable; for sink_not_ready the failure class of the target’s check, such as connect or status.
The HTTP status the target answered, for sink_not_ready, when it answered.
The target’s own error code, for sink_not_ready, when it speaks one, such as a ClickHouse exception or an S3 error code.
object
JSON Pointer into the request body.
The values of the rule broken, such as the bounds of a length, for a client to explain the violation in its own language.
object
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example", "detail": "example", "request_id": "example", "retry_after": 1, "permission": "example", "current_version": 1, "references": [ { "kind": "example", "key": "example", "environment": "example" } ], "provider": "example", "used_by": [ "example" ], "failure": "example", "failure_status": 1, "failure_code": "example", "errors": [ { "pointer": "example", "code": "example", "detail": "example", "params": {} } ]}Headers
Section titled “Headers”The caller may not perform the operation: forbidden (with the
missing permission), session_required, insufficient_scope,
cross_origin for a request signed in by the session cookie, a read
included, that the browser says comes from another origin, or, for a
write, change_request_required when it would change what a
protected environment’s SDKs receive; detail names those
environments.
A problem document (RFC 9457). Code-specific values are further members.
object
Stable snake_case name of the problem, which clients branch on.
An English explanation for humans; never what a client branches on.
Seconds to wait before retrying, for a rate limit.
The permission the caller lacks, for forbidden, or the role’s permission the caller lacks, for role_not_allowed.
The version the entity has now, for version_mismatch.
What still names what the write would remove or hide, for in_use.
object
What names it, such as flag, segment or experiment.
The key of the environment it is named in; null when it is named in every environment.
The slug of the auth provider to sign in through instead, for sso_required.
What keeps an auth provider from being deleted, disabled or edited, for provider_in_use, such as identities, enforced domains or only way in (the only enabled provider while local login is disabled).
Why a system the server asked did not answer as needed, for provider_unreachable; for sink_not_ready the failure class of the target’s check, such as connect or status.
The HTTP status the target answered, for sink_not_ready, when it answered.
The target’s own error code, for sink_not_ready, when it speaks one, such as a ClickHouse exception or an S3 error code.
object
JSON Pointer into the request body.
The values of the rule broken, such as the bounds of a length, for a client to explain the violation in its own language.
object
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example", "detail": "example", "request_id": "example", "retry_after": 1, "permission": "example", "current_version": 1, "references": [ { "kind": "example", "key": "example", "environment": "example" } ], "provider": "example", "used_by": [ "example" ], "failure": "example", "failure_status": 1, "failure_code": "example", "errors": [ { "pointer": "example", "code": "example", "detail": "example", "params": {} } ]}not_found: no such project, or nothing under that identifier in it. An unknown project is answered before any permission is judged.
A problem document (RFC 9457). Code-specific values are further members.
object
Stable snake_case name of the problem, which clients branch on.
An English explanation for humans; never what a client branches on.
Seconds to wait before retrying, for a rate limit.
The permission the caller lacks, for forbidden, or the role’s permission the caller lacks, for role_not_allowed.
The version the entity has now, for version_mismatch.
What still names what the write would remove or hide, for in_use.
object
What names it, such as flag, segment or experiment.
The key of the environment it is named in; null when it is named in every environment.
The slug of the auth provider to sign in through instead, for sso_required.
What keeps an auth provider from being deleted, disabled or edited, for provider_in_use, such as identities, enforced domains or only way in (the only enabled provider while local login is disabled).
Why a system the server asked did not answer as needed, for provider_unreachable; for sink_not_ready the failure class of the target’s check, such as connect or status.
The HTTP status the target answered, for sink_not_ready, when it answered.
The target’s own error code, for sink_not_ready, when it speaks one, such as a ClickHouse exception or an S3 error code.
object
JSON Pointer into the request body.
The values of the rule broken, such as the bounds of a length, for a client to explain the violation in its own language.
object
Example generated
{ "type": "example", "title": "example", "status": 1, "code": "example", "detail": "example", "request_id": "example", "retry_after": 1, "permission": "example", "current_version": 1, "references": [ { "kind": "example", "key": "example", "environment": "example" } ], "provider": "example", "used_by": [ "example" ], "failure": "example", "failure_status": 1, "failure_code": "example", "errors": [ { "pointer": "example", "code": "example", "detail": "example", "params": {} } ]}