Optimizely Features API

Manage features with variables used in feature flag configurations.

Documentation

Specifications

Other Resources

OpenAPI Specification

optimizely-features-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Optimizely Campaign REST Assets Features API
  description: The Optimizely Campaign REST API provides programmatic access to Optimizely's email and omnichannel campaign management capabilities. Developers can use the API to manage campaigns, recipients, mailing lists, smart campaigns, transactional mails, and messaging workflows. The API is hosted at api.campaign.episerver.net and supports automation of marketing campaign operations, enabling integration with external systems and custom marketing workflows. The base URL includes the client ID for multi-tenant access.
  version: '1.0'
  contact:
    name: Optimizely Support
    url: https://support.optimizely.com
  termsOfService: https://www.optimizely.com/legal/terms/
servers:
- url: https://api.campaign.episerver.net/rest
  description: Optimizely Campaign Production Server
security:
- basicAuth: []
tags:
- name: Features
  description: Manage features with variables used in feature flag configurations.
paths:
  /features:
    get:
      operationId: listFeatures
      summary: List features
      description: Returns a list of features for the specified project. Features define variables that can be remotely configured through flags.
      tags:
      - Features
      parameters:
      - $ref: '#/components/parameters/projectIdQuery'
      - $ref: '#/components/parameters/perPage'
      - $ref: '#/components/parameters/page'
      responses:
        '200':
          description: Successfully retrieved the list of features
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Feature'
        '401':
          description: Authentication credentials are missing or invalid
  /features/{feature_id}:
    get:
      operationId: getFeature
      summary: Get a feature
      description: Retrieves the details of a specific feature.
      tags:
      - Features
      parameters:
      - $ref: '#/components/parameters/featureId'
      responses:
        '200':
          description: Successfully retrieved the feature
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Feature'
        '401':
          description: Authentication credentials are missing or invalid
        '404':
          description: Feature not found
components:
  schemas:
    Feature:
      type: object
      description: A feature with configurable variables
      properties:
        id:
          type: integer
          format: int64
          description: Unique identifier for the feature
        key:
          type: string
          description: Unique key for the feature
        project_id:
          type: integer
          format: int64
          description: The project this feature belongs to
        variables:
          type: array
          description: List of variables associated with this feature
          items:
            $ref: '#/components/schemas/Variable'
        created:
          type: string
          format: date-time
          description: Timestamp when the feature was created
        last_modified:
          type: string
          format: date-time
          description: Timestamp when the feature was last modified
    Variable:
      type: object
      description: A variable within a feature flag
      properties:
        key:
          type: string
          description: Unique key for the variable
        type:
          type: string
          description: Data type of the variable
          enum:
          - string
          - integer
          - double
          - boolean
          - json
        default_value:
          type: string
          description: Default value of the variable
  parameters:
    perPage:
      name: per_page
      in: query
      required: false
      description: Number of results per page
      schema:
        type: integer
        default: 25
        minimum: 1
        maximum: 100
    featureId:
      name: feature_id
      in: path
      required: true
      description: The unique identifier for the feature
      schema:
        type: integer
        format: int64
    projectIdQuery:
      name: project_id
      in: query
      required: true
      description: The unique identifier for the project to filter by
      schema:
        type: integer
        format: int64
    page:
      name: page
      in: query
      required: false
      description: Page number for pagination
      schema:
        type: integer
        default: 1
        minimum: 1
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: HTTP Basic authentication using the Optimizely Campaign API credentials.
externalDocs:
  description: Optimizely Campaign REST API Documentation
  url: https://docs.developers.optimizely.com/optimizely-campaign/docs/rest-api