v4

latestOpenAPI 3.0.02026-08-04109113304.5 KB
Search

Search

Search for entities in your account by text string

get/search

Query parameters

per_pageinteger

Optional pagination argument that specifies the maximum number of objects to return per request

pageinteger

Optional pagination argument that specifies the page to return. If you have 140 objects and you choose to return 100 objects per page you will be able to access the last 40 objects on page 2. The default value is 1.

querystring required

The text to search for.

project_idinteger[]

Filters search results by Project ID. Specifying multiple Project IDs will search across all specified projects.

typestring[]

Filters search results by entity type. Specifying multiple types will search across all types specified.

type_expandstring[]

Filters search results by experiment, rule or campaign types. Specifying multiple types will search across all types specified.

project_typestring[]

Filters search results by project type. Specifying multiple types will search across all types specified.

expandstring[]

Include the project name with the search result

archivedboolean

Whether or not to include archived entities in the search results. If this parameter is not provided it will default to false and no archived entities will be included.

fullsearchboolean

Whether or not to perform full document search for the given search keyword. If this parameter is not provided it will default to false.

statusstring[]

Filters search results by the current status of the entity if it has one. Works for Experiments and Campaigns, and it may work for others. Specifying multiple statuses will search for entities with ANY of those statuses.

sortstring

The property to sort by.

orderstring

The property to sort by.

environment_keystring

Filters search result by environment_key when applicable

audience_idinteger[]

Filters search result by audience_id when applicable

Response

Return search results

archivedboolean

Whether or not the entity is archived.

audience_idsinteger[]

A list of Audience IDs used in the Experiment

campaign_typestring

Type of campaing.

createdstring date-time

The time that the entity was created.

descriptionstring

Description for the entity if it has one.

enabledboolean

Wheter or not the environment is enabled or not

environment_keystring

The environment key of a given rule

event_typestring

Type of event.

experiment_countinteger

Number of experiments by audience_id

experiment_typestring

The type of experiment

feature_keystring

The feature flag key

feature_namestring

The feature flag name to display in the Optimizely app. Whitespaces and other non-alphanumeric characters allowed. Defaults to feature key if left empty.

flag_keystring

The Flag key

group_idinteger

The id of the group that the rule belongs to.

idinteger

ID of the entity

keystring

Key of the entity.

last_modifiedstring date-time

The time that the entity was last modified.

namestring

Name of the entity. This value will be the 'key' of the entity if there is no name.

page_idinteger

The Page ID associated with an Event

project_idinteger

ID of the project that contains the entity (if applicable)

project_namestring

Name of the project that contains the entity (if applicable)

rule_typestring

Type of rule.

ruleset_enabledboolean

Wheter or not the a rule is enabled in a ruleset

statusstring

The current status for the entity if it has one.

type'experiment' | 'campaign' | 'feature' | 'audience' | 'page' | 'event' | 'flag' | 'rule' | 'extension'

Type of the entity.

updated_timestring date-time

The time that the flag entity was last modified.

variation_specificboolean

Whether or not an event is variation specific

Example response

[
  {
    "campaign_type": "personalization",
    "description": "Test out the hero image on the home page",
    "environment_key": "development",
    "event_type": "custom",
    "experiment_count": 123,
    "experiment_type": "a/b",
    "feature_key": "my_feature_flag",
    "feature_name": "the user search feature",
    "flag_key": "my_flag_key",
    "group_id": 123,
    "key": "hero_image_test",
    "name": "Hero Image Test",
    "rule_type": "a/b",
    "status": "running",
    "type": "experiment"
  }
]