For the complete documentation index, see llms.txt. This page is also available as Markdown.

Variations

Manage variations

Get variations of the variation group

get

Return the list of the variations of the variation group

Authorizations
AuthorizationstringRequired

Prefix the token with 'Bearer ' to indicate it is a bearer token

Path parameters
account_idstringRequired

The ID of the account

account_environment_idstringRequired

The ID of the environment

campaign_idstringRequired

The ID of the campaign

variation_group_idstringRequired

The ID of the variation group

Query parameters
_pageintegerOptional

Index of the page

Example: 0
_max_per_pageintegerOptional

Number of items per page

Example: 10
Responses
200

Success

application/json
current_item_countinteger · intOptional

Returns the number of items in the current page

current_pageinteger · intOptional

Returns the number of the current page

Default: 0
total_countinteger · intOptional

Returns the number of total items

items_per_pageinteger · intOptional

Returns the number of items per page

Default: 10
last_pageinteger · intOptional

Returns the index of the page

get/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations
GET /v1/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations HTTP/1.1
Host: api.flagship.io
Authorization: YOUR_API_KEY
Accept: */*
{
  "current_item_count": 1,
  "current_page": 0,
  "total_count": 1,
  "items_per_page": 10,
  "last_page": 1,
  "items": [
    {
      "id": "text",
      "name": "text",
      "reference": true,
      "allocation": 1,
      "modifications": {
        "type": "text",
        "value": {}
      }
    }
  ]
}

Create a variation

post

Create a variation

Authorizations
AuthorizationstringRequired

Prefix the token with 'Bearer ' to indicate it is a bearer token

Path parameters
account_idstringRequired

The ID of the account

account_environment_idstringRequired

The ID of the environment

campaign_idstringRequired

The ID of the campaign

variation_group_idstringRequired

The ID of the variation group

Body
idstringRead-onlyOptional

ID of the variation

namestringRequired

Name of the variation

referencebooleanOptional

Wether the variation is the reference or not

allocationintegerRequired

Allocation of the variation (0-100)

Responses
201

Created

application/json
idstringRead-onlyOptional

ID of the variation

namestringRequired

Name of the variation

referencebooleanOptional

Wether the variation is the reference or not

allocationintegerRequired

Allocation of the variation (0-100)

post/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations
POST /v1/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations HTTP/1.1
Host: api.flagship.io
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 90

{
  "name": "text",
  "reference": true,
  "allocation": 1,
  "modifications": {
    "type": "text",
    "value": {}
  }
}
{
  "id": "text",
  "name": "text",
  "reference": true,
  "allocation": 1,
  "modifications": {
    "type": "text",
    "value": {}
  }
}

Get one variation

get

Return one variation by its id

Authorizations
AuthorizationstringRequired

Prefix the token with 'Bearer ' to indicate it is a bearer token

Path parameters
account_idstringRequired

The ID of the account

account_environment_idstringRequired

The ID of the environment

campaign_idstringRequired

The ID of the campaign

variation_group_idstringRequired

The ID of the variation group

variation_idstringRequired

The ID of the variation

Responses
200

Success

application/json
idstringRead-onlyOptional

ID of the variation

namestringRequired

Name of the variation

referencebooleanOptional

Wether the variation is the reference or not

allocationintegerRequired

Allocation of the variation (0-100)

get/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id}
GET /v1/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id} HTTP/1.1
Host: api.flagship.io
Authorization: YOUR_API_KEY
Accept: */*
{
  "id": "text",
  "name": "text",
  "reference": true,
  "allocation": 1,
  "modifications": {
    "type": "text",
    "value": {}
  }
}

Delete a variation

delete

Delete a variation by its id.

Authorizations
AuthorizationstringRequired

Prefix the token with 'Bearer ' to indicate it is a bearer token

Path parameters
account_idstringRequired

The ID of the account

account_environment_idstringRequired

The ID of the environment

campaign_idstringRequired

The ID of the campaign

variation_group_idstringRequired

The ID of the variation group

variation_idstringRequired

The ID of the variation

Responses
204

Deleted

No content

delete/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id}
DELETE /v1/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id} HTTP/1.1
Host: api.flagship.io
Authorization: YOUR_API_KEY
Accept: */*

No content

Update a variation

patch

Update variation informations - You can set only the properies you want to update in the request body.

Authorizations
AuthorizationstringRequired

Prefix the token with 'Bearer ' to indicate it is a bearer token

Path parameters
account_idstringRequired

The ID of the account

account_environment_idstringRequired

The ID of the environment

campaign_idstringRequired

The ID of the campaign

variation_group_idstringRequired

The ID of the variation group

variation_idstringRequired

The ID of the variation

Body
idstringRead-onlyOptional

ID of the variation

namestringRequired

Name of the variation

referencebooleanOptional

Wether the variation is the reference or not

allocationintegerRequired

Allocation of the variation (0-100)

Responses
200

Updated

application/json
idstringRead-onlyOptional

ID of the variation

namestringRequired

Name of the variation

referencebooleanOptional

Wether the variation is the reference or not

allocationintegerRequired

Allocation of the variation (0-100)

patch/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id}
PATCH /v1/accounts/{account_id}/account_environments/{account_environment_id}/campaigns/{campaign_id}/variation_groups/{variation_group_id}/variations/{variation_id} HTTP/1.1
Host: api.flagship.io
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 90

{
  "name": "text",
  "reference": true,
  "allocation": 1,
  "modifications": {
    "type": "text",
    "value": {}
  }
}
{
  "id": "text",
  "name": "text",
  "reference": true,
  "allocation": 1,
  "modifications": {
    "type": "text",
    "value": {}
  }
}

Last updated

Was this helpful?