openapi: 3.0.3 info: title: Unleash Admin Addons Import/Export API version: 7.4.1 description: Create, update, and delete [Unleash addons](https://docs.getunleash.io/addons). servers: - url: https://app.unleash-instance.example.com description: Your Unleash instance (replace with your actual URL) security: - apiKey: [] - bearerToken: [] tags: - name: Import/Export description: '[Import and export](https://docs.getunleash.io/concepts/import-export) the state of your Unleash instance.' paths: /api/admin/features-batch/export: post: tags: - Import/Export operationId: exportFeatures requestBody: description: exportQuerySchema required: true content: application/json: schema: $ref: '#/components/schemas/exportQuerySchema' responses: '200': description: exportResultSchema content: application/json: schema: $ref: '#/components/schemas/exportResultSchema' '404': description: The requested resource was not found. content: application/json: schema: type: object properties: id: type: string example: 9c40958a-daac-400e-98fb-3bb438567008 description: The ID of the error instance name: type: string example: NotFoundError description: The name of the error kind message: type: string example: Could not find the addon with ID "12345". description: A description of what went wrong. description: Exports all features listed in the `features` property from the environment specified in the request body. If set to `true`, the `downloadFile` property will let you download a file with the exported data. Otherwise, the export data is returned directly as JSON. Refer to the documentation for more information about [Unleash's export functionality](https://docs.getunleash.io/concepts/import-export#export-feature-flags). summary: Export Feature Flags From an Environment /api/admin/features-batch/validate: post: tags: - Import/Export operationId: validateImport requestBody: description: importTogglesSchema required: true content: application/json: schema: $ref: '#/components/schemas/importTogglesSchema' responses: '200': description: importTogglesValidateSchema content: application/json: schema: $ref: '#/components/schemas/importTogglesValidateSchema' '404': description: The requested resource was not found. content: application/json: schema: type: object properties: id: type: string example: 9c40958a-daac-400e-98fb-3bb438567008 description: The ID of the error instance name: type: string example: NotFoundError description: The name of the error kind message: type: string example: Could not find the addon with ID "12345". description: A description of what went wrong. summary: Validate Feature Import Data description: Validates a feature flag data set. Checks whether the data can be imported into the specified project and environment. The returned value is an object that contains errors, warnings, and permissions required to perform the import, as described in the [import documentation](https://docs.getunleash.io/concepts/import-export#import-feature-flags). /api/admin/features-batch/import: post: tags: - Import/Export operationId: importToggles requestBody: description: importTogglesSchema required: true content: application/json: schema: $ref: '#/components/schemas/importTogglesSchema' responses: '200': description: This response has no body. '404': description: The requested resource was not found. content: application/json: schema: type: object properties: id: type: string example: 9c40958a-daac-400e-98fb-3bb438567008 description: The ID of the error instance name: type: string example: NotFoundError description: The name of the error kind message: type: string example: Could not find the addon with ID "12345". description: A description of what went wrong. summary: Import Feature Flags description: '[Import feature flags](https://docs.getunleash.io/concepts/import-export#import-feature-flags) into a specific project and environment.' components: schemas: constraintSchema: additionalProperties: false type: object required: - contextName - operator description: A strategy constraint. For more information, refer to [the strategy constraint reference documentation](https://docs.getunleash.io/concepts/activation-strategies#constraints) properties: contextName: description: The name of the context field that this constraint should apply to. example: appName type: string operator: description: The operator to use when evaluating this constraint. For more information about the various operators, refer to [the strategy constraint operator documentation](https://docs.getunleash.io/concepts/activation-strategies#constraint-operators). type: string enum: - NOT_IN - IN - STR_ENDS_WITH - STR_STARTS_WITH - STR_CONTAINS - NUM_EQ - NUM_GT - NUM_GTE - NUM_LT - NUM_LTE - DATE_AFTER - DATE_BEFORE - SEMVER_EQ - SEMVER_GT - SEMVER_LT example: IN caseInsensitive: description: Whether the operator should be case sensitive or not. Defaults to `false` (being case sensitive). type: boolean default: false inverted: description: Whether the result should be negated or not. If `true`, will turn a `true` result into a `false` result and vice versa. type: boolean default: false values: type: array description: The context values that should be used for constraint evaluation. Use this property instead of `value` for properties that accept multiple values. items: type: string example: - my-app - my-other-app value: description: The context value that should be used for constraint evaluation. Use this property instead of `values` for properties that only accept single values. type: string example: my-app featureSchema: type: object additionalProperties: false required: - name description: A feature flag definition properties: name: type: string example: disable-comments description: Unique feature name type: type: string example: kill-switch description: Type of the flag e.g. experiment, kill-switch, release, operational, permission description: type: string nullable: true example: Controls disabling of the comments section in case of an incident description: Detailed description of the feature archived: type: boolean example: true description: '`true` if the feature is archived' project: type: string example: dx-squad description: Name of the project the feature belongs to enabled: type: boolean example: true description: '`true` if the feature is enabled, otherwise `false`.' stale: type: boolean example: false description: '`true` if the feature is stale based on the age and feature type, otherwise `false`.' favorite: type: boolean example: true description: '`true` if the feature was favorited, otherwise `false`.' impressionData: type: boolean example: false description: '`true` if the impression data collection is enabled for the feature, otherwise `false`.' createdAt: type: string format: date-time nullable: true example: '2023-01-28T15:21:39.975Z' description: The date the feature was created createdBy: type: object description: User who created the feature flag additionalProperties: false required: - id - name - imageUrl properties: id: description: The user id type: integer example: 123 name: description: Name of the user type: string example: User imageUrl: description: URL used for the user profile image type: string example: https://example.com/242x200.png archivedAt: type: string format: date-time nullable: true example: '2023-01-29T15:21:39.975Z' description: The date the feature was archived lastSeenAt: type: string format: date-time nullable: true deprecated: true example: '2023-01-28T16:21:39.975Z' description: The date when metrics where last collected for the feature. This field was deprecated in v5, use the one in featureEnvironmentSchema environments: type: array items: $ref: '#/components/schemas/featureEnvironmentSchema' description: The list of environments where the feature can be used variants: type: array items: $ref: '#/components/schemas/variantSchema' description: The list of feature variants deprecated: true strategies: type: array items: type: object description: This was deprecated in v5 and will be removed in a future major version deprecated: true tags: type: array items: $ref: '#/components/schemas/tagSchema' nullable: true description: The list of feature tags children: type: array description: The list of child feature names. This is an experimental field and may change. items: type: string example: some-feature lifecycle: type: object description: Current lifecycle stage of the feature additionalProperties: false required: - stage - enteredStageAt properties: stage: description: The name of the current lifecycle stage type: string enum: - initial - pre-live - live - completed - archived example: initial status: type: string nullable: true example: kept description: The name of the detailed status of a given stage. E.g. completed stage can be kept or discarded. enteredStageAt: description: When the feature entered this stage type: string format: date-time example: '2023-01-28T15:21:39.975Z' dependencies: type: array items: type: object additionalProperties: false required: - feature properties: feature: description: The name of the parent feature type: string example: some-feature enabled: description: Whether the parent feature is enabled or not type: boolean example: true variants: description: The list of variants the parent feature should resolve to. Only valid when feature is enabled. type: array items: example: some-feature-blue-variant type: string description: The list of parent dependencies. This is an experimental field and may change. collaborators: type: object required: - users description: Information related to users who have made changes to this feature flage. properties: users: description: Users who have made any changes to this feature flags. The list is sorted in reverse chronological order (most recent changes first) type: array items: type: object required: - id - name - imageUrl description: A simple representation of a user. properties: id: description: The user's id type: integer example: 123 name: description: The user's name, username, or email (prioritized in that order). If none of those are present, this property will be set to the string `unknown` type: string example: User imageUrl: description: The URL to the user's profile image type: string example: https://example.com/242x200.png links: type: array items: type: object additionalProperties: false required: - id - url properties: id: type: string example: 01JTJNCJ5XVP2KPJFA03YRBZCA description: The id of the link url: type: string example: https://github.com/search?q=cleanupReminder&type=code description: The URL the feature is linked to title: type: string example: Github cleanup description: The description of the link nullable: true feature: type: string example: disable-comments description: The name of the feature this link belongs to description: The list of links. This is an experimental field and may change. featureLinkSchema: type: object required: - url properties: url: type: string example: https://github.com/search?q=cleanupReminder&type=code description: The URL the feature is linked to title: type: string example: Github cleanup description: The description of the link nullable: true description: The link to any URL related to the feature featureStrategySchema: description: A single activation strategy configuration schema for a feature type: object additionalProperties: false required: - name properties: id: type: string description: A uuid for the feature strategy example: 6b5157cb-343a-41e7-bfa3-7b4ec3044840 name: type: string description: The name or type of strategy example: flexibleRollout title: type: string description: A descriptive title for the strategy example: Gradual Rollout 25-Prod nullable: true disabled: type: boolean description: A toggle to disable the strategy. defaults to false. Disabled strategies are not evaluated or returned to the SDKs example: false nullable: true featureName: type: string description: The name or feature the strategy is attached to example: myAwesomeFeature sortOrder: type: number description: The order of the strategy in the list example: 9999 segments: type: array description: A list of segment ids attached to the strategy example: - 1 - 2 items: type: number constraints: type: array description: A list of the constraints attached to the strategy. See https://docs.getunleash.io/concepts/activation-strategies#constraints items: $ref: '#/components/schemas/constraintSchema' variants: type: array description: Strategy level variants items: $ref: '#/components/schemas/strategyVariantSchema' parameters: $ref: '#/components/schemas/parametersSchema' featureDependenciesSchema: type: object description: Feature dependency connection between a child feature and its dependencies required: - feature - dependencies additionalProperties: false properties: feature: type: string description: The name of the child feature. example: child_feature dependencies: type: array description: List of parent features for the child feature items: $ref: '#/components/schemas/dependentFeatureSchema' importTogglesSchema: type: object required: - project - environment - data additionalProperties: false description: The result of the export operation for a project and environment, used at import properties: project: type: string example: My awesome project description: The exported [project](https://docs.getunleash.io/concepts/projects) environment: type: string example: development description: The exported [environment](https://docs.getunleash.io/concepts/environments) data: $ref: '#/components/schemas/exportResultSchema' importTogglesValidateItemSchema: type: object required: - message - affectedItems additionalProperties: false description: A description of an error or warning pertaining to a feature flag import job. properties: message: type: string description: The validation error message example: 'You cannot import a feature that already exist in other projects. You already have the following features defined outside of project default:' affectedItems: type: array description: 'The items affected by this error message ' example: - some-feature-a - some-feature-b items: type: string variantSchema: type: object additionalProperties: false description: A variant allows for further separation of users into segments. See [our excellent documentation](https://docs.getunleash.io/concepts/feature-flag-variants#what-are-variants) for a more detailed description required: - name - weight properties: name: type: string description: The variants name. Is unique for this feature flag example: blue_group weight: type: number description: The weight is the likelihood of any one user getting this variant. It is a number between 0 and 1000. See the section on [variant weights](https://docs.getunleash.io/concepts/feature-flag-variants#variant-weight) for more information minimum: 0 maximum: 1000 weightType: description: Set to fix if this variant must have exactly the weight allocated to it. If the type is variable, the weight will adjust so that the total weight of all variants adds up to 1000 type: string example: variable enum: - variable - fix stickiness: type: string description: '[Stickiness](https://docs.getunleash.io/concepts/feature-flag-variants#variant-stickiness) is how Unleash guarantees that the same user gets the same variant every time' example: custom.context.field payload: type: object required: - type - value description: Extra data configured for this variant additionalProperties: false properties: type: description: The type of the value. Commonly used types are string, number, json and csv. type: string enum: - json - csv - string - number value: description: The actual value of payload type: string example: type: json value: '{"color": "red"}' overrides: description: Overrides assigning specific variants to specific users. The weighting system automatically assigns users to specific groups for you, but any overrides in this list will take precedence. type: array items: $ref: '#/components/schemas/overrideSchema' releasePlanMilestoneStrategySchema: additionalProperties: false description: Schema representing the creation of a release plan milestone strategy. type: object required: - id - milestoneId - sortOrder - strategyName properties: id: type: string description: The milestone strategy's ID. Milestone strategy IDs are ulids. example: 01JB9GGTGQYEQ9D40R17T3YVW3 nullable: false milestoneId: type: string description: The ID of the milestone that this strategy belongs to. example: 01JB9GGTGQYEQ9D40R17T3YVW1 sortOrder: type: number description: The order of the strategy in the list example: 9999 title: type: string nullable: true description: A descriptive title for the strategy example: Gradual Rollout 25-Prod strategyName: type: string description: The name of the strategy type example: flexibleRollout parameters: description: An object containing the parameters for the strategy example: groupId: some_new rollout: '25' stickiness: sessionId $ref: '#/components/schemas/parametersSchema' constraints: type: array description: A list of the constraints attached to the strategy. See https://docs.getunleash.io/concepts/activation-strategies#constraints example: - values: - '1' - '2' inverted: false operator: IN contextName: appName caseInsensitive: false items: $ref: '#/components/schemas/constraintSchema' variants: type: array description: Strategy level variants items: $ref: '#/components/schemas/createStrategyVariantSchema' segments: type: array description: Ids of segments to use for this strategy example: - 1 - 2 items: type: number overrideSchema: type: object additionalProperties: false required: - contextName - values description: An override for deciding which variant should be assigned to a user based on the context name properties: contextName: description: The name of the context field used to determine overrides type: string example: userId values: description: Which values that should be overriden type: array items: type: string example: - red - blue tagTypeSchema: type: object additionalProperties: false description: A tag type. required: - name properties: name: type: string description: The name of the tag type. example: color description: type: string description: The description of the tag type. example: A tag type for describing the color of a tag. icon: type: string nullable: true description: The icon of the tag type. example: not-really-used color: type: string nullable: true description: The hexadecimal color code for the tag type. example: '#FFFFFF' pattern: ^#[0-9A-Fa-f]{6}$ dependentFeatureSchema: type: object description: Feature dependency on a parent feature in read model required: - feature additionalProperties: false properties: feature: type: string description: The name of the feature we depend on. example: parent_feature enabled: type: boolean description: Whether the parent feature should be enabled. When `false` variants are ignored. `true` by default. example: false variants: type: array description: The list of variants the parent feature should resolve to. Leave empty when you only want to check the `enabled` status. items: type: string example: - variantA - variantB releasePlanMilestoneSchema: additionalProperties: false description: Schema representing the creation of a release plan milestone. type: object required: - id - name - sortOrder - releasePlanDefinitionId properties: id: type: string description: The milestone's ID. Milestone IDs are ulids. example: 01JB9GGTGQYEQ9D40R17T3YVW1 nullable: false name: type: string description: The name of the milestone. example: My milestone sortOrder: type: integer description: The order of the milestone in the release plan. example: 1 releasePlanDefinitionId: type: string description: The ID of the release plan/template that this milestone belongs to. example: 01JB9GGTGQYEQ9D40R17T3YVW2 startedAt: type: string format: date-time description: The date and time when the milestone was started. example: '2024-01-01T00:00:00.000Z' nullable: true transitionCondition: type: object additionalProperties: false required: - intervalMinutes properties: intervalMinutes: type: integer minimum: 1 description: The interval in minutes before transitioning example: 30 description: The condition configuration for the transition nullable: true progressionExecutedAt: type: string format: date-time description: The date and time when the milestone progression was executed. example: '2024-01-01T00:00:00.000Z' nullable: true pausedAt: type: string format: date-time description: The date and time when the milestone was paused. example: '2024-01-01T00:00:00.000Z' nullable: true strategies: type: array description: A list of strategies that are attached to this milestone. items: $ref: '#/components/schemas/releasePlanMilestoneStrategySchema' releasePlanSchema: additionalProperties: false description: Schema representing the creation of a release plan. type: object required: - id - discriminator - name - featureName - environment - createdByUserId - createdAt - milestones - releasePlanTemplateId properties: id: type: string description: The release plan/template's ID. Release template IDs are ulids. example: 01JB9GGTGQYEQ9D40R17T3YVW2 nullable: false discriminator: type: string description: A field to distinguish between release plans and release templates. example: plan nullable: false enum: - plan name: type: string description: The name of the release template. example: My release plan description: type: string description: A description of the release template. example: This is my release plan nullable: true featureName: type: string description: The name of the feature that uses this release plan. example: my-feature environment: type: string description: The environment that this release plan is for. example: production createdByUserId: type: number description: 'Release template: The ID of the user who created this template.' example: 53 nullable: false createdAt: type: string format: date-time description: The date and time that the release template was created. example: '2022-01-01T00:00:00Z' nullable: false activeMilestoneId: type: string description: The ID of the currently active milestone in this release plan. example: 01JB9GGTGQYEQ9D40R17T3YVW1 nullable: true milestones: type: array description: A list of the milestones in this release template. items: $ref: '#/components/schemas/releasePlanMilestoneSchema' releasePlanTemplateId: type: string description: The ID of the release plan template that this release plan is based on. example: 01JB9GGTGQYEQ9D40R17T3YVW2 nullable: false safeguards: type: array description: An array of safeguards configured for this release plan. items: $ref: '#/components/schemas/safeguardSchema' contextFieldSchema: type: object additionalProperties: false description: A representation of a [context field](https://docs.getunleash.io/concepts/unleash-context). required: - name properties: name: description: The name of the context field type: string example: userId description: description: The description of the context field. type: string nullable: true example: Used to uniquely identify users stickiness: description: Does this context field support being used for [stickiness](https://docs.getunleash.io/concepts/stickiness) calculations type: boolean example: true sortOrder: description: Used when sorting a list of context fields. Is also used as a tiebreaker if a list of context fields is sorted alphabetically. type: integer example: 900 createdAt: description: When this context field was created type: string format: date-time nullable: true example: '2023-06-29T10:19:00.000Z' usedInFeatures: type: integer description: Number of projects where this context field is used in example: 3 nullable: true minimum: 0 usedInProjects: type: integer description: Number of projects where this context field is used in example: 2 nullable: true minimum: 0 legalValues: description: Allowed values for this context field schema. Can be used to narrow down accepted input type: array items: $ref: '#/components/schemas/legalValueSchema' project: description: The project this context field belongs to (if it is project-specific) type: string example: my-project importTogglesValidateSchema: type: object required: - errors - warnings additionalProperties: false description: An object containing [feature import](https://docs.getunleash.io/concepts/import-export) validation results. properties: errors: description: A list of errors that prevent the provided data from being successfully imported. type: array example: - message: 'You cannot import a feature that already exist in other projects. You already have the following features defined outside of project default:' affectedItems: - my-feature (in project project-854) items: $ref: '#/components/schemas/importTogglesValidateItemSchema' warnings: type: array description: A list of warnings related to the provided data. example: - message: 'The following strategy types will be used in import. Please make sure the strategy type parameters are configured as in source environment:' affectedItems: - custom-strategy-7 items: $ref: '#/components/schemas/importTogglesValidateItemSchema' permissions: type: array description: Any additional permissions required to import the data. If the list is empty, you require no additional permissions beyond what your user already has. items: $ref: '#/components/schemas/importTogglesValidateItemSchema' example: [] featureLinksSchema: type: object description: A list of links for a feature required: - feature - links additionalProperties: false properties: feature: type: string description: The name of the child feature. example: child_feature links: type: array description: List of feature links items: $ref: '#/components/schemas/featureLinkSchema' safeguardSchema: type: object required: - id - action - triggerCondition - impactMetric description: A safeguard configuration for a release plan. additionalProperties: false properties: id: type: string description: The unique ULID identifier for this safeguard example: 01JB9GGTGQYEQ9D40R17T3YVW1 action: type: object required: - type - id additionalProperties: false description: The action to take when the safeguard is triggered. properties: type: type: string description: The type of action to perform. example: pauseReleasePlanProgressions id: type: string description: The ID of the release plan this safeguard applies to. example: 01JB9GGTGQYEQ9D40R17T3YVW2 triggerCondition: $ref: '#/components/schemas/safeguardTriggerConditionSchema' description: The condition that triggers the safeguard. impactMetric: type: object required: - id - metricName - timeRange - aggregationMode - labelSelectors additionalProperties: false properties: id: type: string description: The unique identifier for this impact metric example: 01JB9GGTGQYEQ9D40R17T3YVW1 metricName: type: string description: The Prometheus metric series to query. It includes both unleash prefix and metric type and display name example: unleash_counter_feature_toggle_usage_total timeRange: type: string enum: - hour - day - week - month description: The time range for the metric data. example: day aggregationMode: type: string description: The aggregation mode for the metric data. enum: - rps - count - avg - sum - p95 - p99 - p50 example: rps labelSelectors: type: object additionalProperties: type: array items: type: string description: The selected labels and their values for filtering the metric data. example: environment: - development project: - default description: The metric configuration used to evaluate the safeguard condition. featureTagSchema: type: object description: Describes a tag applied to a feature additionalProperties: false required: - featureName - tagValue properties: featureName: type: string example: my-feature description: The name of the feature this tag is applied to tagType: type: string example: simple description: The [type](https://docs.getunleash.io/concepts/feature-flags#tags) of the tag tagValue: type: string example: my-tag description: The value of the tag type: deprecated: true type: string description: The [type](https://docs.getunleash.io/concepts/feature-flags#tags) of the tag. This property is deprecated and will be removed in a future version of Unleash. Superseded by the `tagType` property. value: deprecated: true type: string description: The value of the tag. This property is deprecated and will be removed in a future version of Unleash. Superseded by the `tagValue` property. createdByUserId: type: number nullable: true example: 1 description: The id of the user who created this tag featureEnvironmentSchema: type: object additionalProperties: false required: - name - enabled description: A detailed description of the feature environment properties: name: type: string example: my-dev-env description: The name of the environment featureName: type: string example: disable-comments description: The name of the feature environment: type: string example: development description: The name of the environment type: type: string example: development description: The type of the environment enabled: type: boolean example: true description: '`true` if the feature is enabled for the environment, otherwise `false`.' sortOrder: type: number example: 3 description: The sort order of the feature environment in the feature environments list variantCount: type: number description: The number of defined variants strategies: type: array items: $ref: '#/components/schemas/featureStrategySchema' description: A list of activation strategies for the feature environment variants: type: array items: $ref: '#/components/schemas/variantSchema' description: A list of variants for the feature environment changeRequestIds: type: array items: type: number description: Experimental. A list of change request identifiers for actionable change requests that are not Cancelled, Rejected or Approved. milestoneName: type: string example: Phase One description: 'Experimental: The name of the currently active release plan milestone' milestoneOrder: type: number example: 0 description: 'Experimental: The zero-indexed order of currently active milestone in the list of all release plan milestones' totalMilestones: type: number example: 0 description: 'Experimental: The total number of milestones in the feature environment release plan' lastSeenAt: type: string format: date-time nullable: true example: '2023-01-28T16:21:39.975Z' description: The date when metrics where last collected for the feature environment hasStrategies: type: boolean description: Whether the feature has any strategies defined. hasEnabledStrategies: type: boolean description: Whether the feature has any enabled strategies defined. releasePlans: type: array description: Release plans for this feature environment (only available when milestoneProgression feature flag is enabled) items: $ref: '#/components/schemas/releasePlanSchema' 'yes': type: integer description: How many times the feature evaluated to true (enabled) example: 974 minimum: 0 'no': type: integer description: How many times the feature evaluated to false (disabled) example: 50 minimum: 0 exportResultSchema: type: object additionalProperties: false description: The result of the export operation, providing you with the feature flag definitions, strategy definitions and the rest of the elements relevant to the features (tags, environments etc.) required: - features - featureStrategies - tagTypes properties: features: type: array description: All the exported features. example: - name: my-feature description: best feature ever type: release project: default stale: false impressionData: false archived: false items: $ref: '#/components/schemas/featureSchema' featureStrategies: type: array description: All strategy instances that are used by the exported features in the `features` list. example: - name: flexibleRollout id: 924974d7-8003-43ee-87eb-c5f887c06fd1 featureName: my-feature title: Rollout 50% parameters: groupId: default rollout: '50' stickiness: random constraints: [] disabled: false segments: - 1 items: $ref: '#/components/schemas/featureStrategySchema' featureEnvironments: type: array description: Environment-specific configuration for all the features in the `features` list. Includes data such as whether the feature is enabled in the selected export environment, whether there are any variants assigned, etc. example: - enabled: true featureName: my-feature environment: development variants: - name: a weight: 500 overrides: [] stickiness: random weightType: variable - name: b weight: 500 overrides: [] stickiness: random weightType: variable name: variant-testing items: $ref: '#/components/schemas/featureEnvironmentSchema' contextFields: type: array description: A list of all the context fields that are in use by any of the strategies in the `featureStrategies` list. example: - name: appName description: Allows you to constrain on application name stickiness: false sortOrder: 2 legalValues: [] items: $ref: '#/components/schemas/contextFieldSchema' featureTags: type: array description: A list of all the tags that have been applied to any of the features in the `features` list. example: - featureName: my-feature tagType: simple tagValue: user-facing items: $ref: '#/components/schemas/featureTagSchema' segments: type: array description: A list of all the segments that are used by the strategies in the `featureStrategies` list. example: - id: 1 name: new-segment-name items: type: object additionalProperties: false required: - id - name properties: id: type: number name: type: string tagTypes: type: array description: A list of all of the tag types that are used in the `featureTags` list. example: - name: simple description: Used to simplify filtering of features icon: '#' items: $ref: '#/components/schemas/tagTypeSchema' dependencies: type: array description: A list of all the dependencies for features in `features` list. items: $ref: '#/components/schemas/featureDependenciesSchema' links: type: array description: A list of links for features in `features` list. items: $ref: '#/components/schemas/featureLinksSchema' legalValueSchema: type: object additionalProperties: false description: Describes a legal value. Typically used to limit possible values for contextFields or strategy properties required: - value properties: value: description: The valid value type: string example: '#c154c1' description: description: Describes this specific legal value type: string example: Deep fuchsia tagSchema: type: object description: Representation of a [tag](https://docs.getunleash.io/concepts/feature-flags#tags) additionalProperties: false required: - value - type properties: value: type: string description: The value of the tag. minLength: 2 maxLength: 50 example: a-tag-value type: type: string minLength: 2 maxLength: 50 description: The [type](https://docs.getunleash.io/concepts/feature-flags#tags) of the tag example: simple color: type: string description: The hexadecimal color code for the tag type. example: '#FFFFFF' pattern: ^#[0-9A-Fa-f]{6}$ nullable: true exportQuerySchema: type: object description: Available query parameters for the deprecated export/import functionality. anyOf: - required: - environment - features properties: environment: type: string example: development description: The environment to export from downloadFile: type: boolean example: true description: Whether to return a downloadable file features: type: array example: - MyAwesomeFeature items: type: string minLength: 1 description: Selects features to export by name. If the list is empty all features are returned. - required: - environment - tag properties: environment: type: string example: development description: The environment to export from downloadFile: type: boolean example: true description: Whether to return a downloadable file tag: type: string example: release description: Selects features to export by tag. - required: - environment - project properties: environment: type: string example: development description: The environment to export from downloadFile: type: boolean example: true description: Whether to return a downloadable file project: type: string example: my-project description: Selects project to export the features from. Used when no tags or features are provided. parametersSchema: type: object description: A list of parameters for a strategy additionalProperties: type: string safeguardTriggerConditionSchema: type: object required: - operator - threshold additionalProperties: false description: The condition that triggers the safeguard. properties: operator: type: string enum: - '>' - < description: The comparison operator for the threshold check. example: '>' threshold: type: number description: The threshold value to compare against. example: 100 strategyVariantSchema: type: object additionalProperties: false description: This is an experimental property. It may change or be removed as we work on it. Please don't depend on it yet. A strategy variant allows you to attach any data to strategies instead of only returning `true`/`false`. Strategy variants take precedence over feature variants. required: - name - weight - weightType - stickiness properties: name: type: string description: The variant name. Must be unique for this feature flag example: blue_group weight: type: integer description: The weight is the likelihood of any one user getting this variant. It is an integer between 0 and 1000. See the section on [variant weights](https://docs.getunleash.io/concepts/feature-flag-variants#variant-weight) for more information minimum: 0 maximum: 1000 weightType: description: Set to `fix` if this variant must have exactly the weight allocated to it. If the type is `variable`, the weight will adjust so that the total weight of all variants adds up to 1000. Refer to the [variant weight documentation](https://docs.getunleash.io/concepts/feature-flag-variants#variant-weight). type: string example: fix enum: - variable - fix stickiness: type: string description: The [stickiness](https://docs.getunleash.io/concepts/feature-flag-variants#variant-stickiness) to use for distribution of this variant. Stickiness is how Unleash guarantees that the same user gets the same variant every time example: custom.context.field payload: type: object required: - type - value description: Extra data configured for this variant properties: type: description: The type of the value. Commonly used types are string, number, json and csv. type: string enum: - json - csv - string - number value: description: The actual value of payload type: string example: type: json value: '{"color": "red"}' createStrategyVariantSchema: type: object description: This is an experimental property. It may change or be removed as we work on it. Please don't depend on it yet. A strategy variant allows you to attach any data to strategies instead of only returning `true`/`false`. Strategy variants take precedence over feature variants. required: - name - weight - weightType - stickiness properties: name: type: string description: The variant name. Must be unique for this feature flag example: blue_group weight: type: integer description: The weight is the likelihood of any one user getting this variant. It is an integer between 0 and 1000. See the section on [variant weights](https://docs.getunleash.io/concepts/feature-flag-variants#variant-weight) for more information minimum: 0 maximum: 1000 weightType: description: Set to `fix` if this variant must have exactly the weight allocated to it. If the type is `variable`, the weight will adjust so that the total weight of all variants adds up to 1000. Refer to the [variant weight documentation](https://docs.getunleash.io/concepts/feature-flag-variants#variant-weight). type: string example: fix enum: - variable - fix stickiness: type: string description: The [stickiness](https://docs.getunleash.io/concepts/feature-flag-variants#variant-stickiness) to use for distribution of this variant. Stickiness is how Unleash guarantees that the same user gets the same variant every time example: custom.context.field payload: type: object required: - type - value description: Extra data configured for this variant properties: type: description: The type of the value. Commonly used types are string, number, json and csv. type: string enum: - json - csv - string - number value: description: The actual value of payload type: string example: type: json value: '{"color": "red"}' securitySchemes: apiKey: type: apiKey in: header name: Authorization description: API key needed to access this API bearerToken: type: http scheme: bearer description: API key needed to access this API, in Bearer token format