PATCH /features/{feature_id}

Update a feature by ID.

Servers

Path parameters

Name Type Required Description
feature_id Integer Yes

The unique identifier for the Feature

Request headers

Name Type Required Description
Content-Type String Yes The media type of the request body.

Default value: "application/json"

Request body fields

Name Type Required Description
environments Object No

The configuration for this Feature's Rollout within each Environment, keyed by Environment key.

environments.name Object No
environments.name.id Integer No

The ID of the Environment this set of Rollout Rules applies to

environments.name.rollout_rules[] Array Yes

Rollout Rules allow you to define groups of users and a percentage of those users that will see a Feature by default. You are currently limited to a single rollout rule. Audience IDs sent in any environment must always match that of the primary environment.

environments.name.rollout_rules[].percentage_included Integer No

The percentage of the designated audiences that should get this Feature, measured in basis points. 100 basis points = 1% traffic.

Default value: 0

environments.name.rollout_rules[].audience_conditions String No

The audiences that should see this feature. To target everyone, use the string "everyone". Multiple audiences can be combined with "and" or "or" using the same structure as audience conditions. audience_conditions sent in any environment must always match those of the primary environment.

environments.name.rollout_rules[].variable_values Object No

The configuration for this Variable's within each Feature Environment, keyed by Variable Key

environments.name.rollout_rules[].enabled Boolean No

Whether or not the Rollout Rule is applied in this Environment. You can toggle this on and off by sending True or False.

Default value: false

environments.name.is_primary Boolean No

Whether the Environment this set of Rollout Rules applies to is the primary Environment

name String No

Name of the Feature

archived Boolean No

Whether the Feature has been archived

description String No

A short description of this Feature

key String No

Unique string identifier for this Feature within the Project

variables[] Array No

Variables define the dynamic configuration of a feature, and each variable can take on a different value on a per-variation basis within a feature test.

variables[].id Integer No

The ID of this Feature Variable

variables[].default_value String No

The stringified default value for this Feature Variable. The default value is the value Optimizely SDKs will return when this Feature Variable is accessed by getFeatureVariableValue unless the Feature Variable's value is a part of a feature test variation.

variables[].archived Boolean No

Whether or not this Feature Variable is archived

Default value: false

variables[].description String No

A short description of this Feature Variable

variables[].key String No

Unique string identifier for this Feature Variable within the Feature

variables[].type String No

The datatype for this Feature Variable

Valid values:

  • "double"
  • "string"
  • "boolean"
  • "integer"
  • "json"

How to start integrating

  1. Add HTTP Task to your workflow definition.
  2. Search for the API you want to integrate with and click on the name.
    • This loads the API reference documentation and prepares the Http request settings.
  3. Click Test request to test run your request to the API and see the API's response.