Experimentation - Update Experiment

Updates an existing experiment for a title.

POST https://titleId.playfabapi.com/Experimentation/UpdateExperiment

Request Header

Name Required Type Description
X-EntityToken True
  • string

This API requires an Entity Session Token, available from the Entity GetEntityToken method.

Request Body

Name Required Type Description
Id True
  • string

Id of the experiment.

Name True
  • string

Friendly name of the experiment.

StartDate True
  • string

When experiment should start.

Variants True

List of variants for the experiment.

CustomTags
  • object

The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.).

Description
  • string

Description of the experiment.

EndDate
  • string

When experiment should end.

ExclusionGroupId
  • string

Id of the exclusion group.

ExclusionGroupTrafficAllocation
  • number

Percentage of exclusion group traffic that will see this experiment.

ExperimentType

Type of experiment.

SegmentId
  • string

Id of the segment to which this experiment applies. Defaults to the 'All Players' segment.

TitlePlayerAccountTestIds
  • string[]

List of title player account IDs that automatically receive treatments in the experiment, but are not included when calculating experiment metrics.

Responses

Name Type Description
200 OK
400 Bad Request

This is the outer wrapper for all responses with errors

Security

X-EntityToken

This API requires an Entity Session Token, available from the Entity GetEntityToken method.

Type: apiKey
In: header

Definitions

ApiErrorWrapper

The basic wrapper around every failed API response

EmptyResponse
ExperimentType
UpdateExperimentRequest

Given a title entity token and experiment details, this API updates the experiment. If an experiment is already running, only the description and duration properties can be updated.

Variable
Variant

ApiErrorWrapper

The basic wrapper around every failed API response

Name Type Description
code
  • integer

Numerical HTTP code

error
  • string

Playfab error code

errorCode
  • integer

Numerical PlayFab error code

errorDetails
  • object

Detailed description of individual issues with the request object

errorMessage
  • string

Description for the PlayFab errorCode

status
  • string

String HTTP code

EmptyResponse

ExperimentType

Name Type Description
Active
  • string
Snapshot
  • string

UpdateExperimentRequest

Given a title entity token and experiment details, this API updates the experiment. If an experiment is already running, only the description and duration properties can be updated.

Name Type Description
CustomTags
  • object

The optional custom tags associated with the request (e.g. build number, external trace identifiers, etc.).

Description
  • string

Description of the experiment.

EndDate
  • string

When experiment should end.

ExclusionGroupId
  • string

Id of the exclusion group.

ExclusionGroupTrafficAllocation
  • number

Percentage of exclusion group traffic that will see this experiment.

ExperimentType

Type of experiment.

Id
  • string

Id of the experiment.

Name
  • string

Friendly name of the experiment.

SegmentId
  • string

Id of the segment to which this experiment applies. Defaults to the 'All Players' segment.

StartDate
  • string

When experiment should start.

TitlePlayerAccountTestIds
  • string[]

List of title player account IDs that automatically receive treatments in the experiment, but are not included when calculating experiment metrics.

Variants

List of variants for the experiment.

Variable

Name Type Description
Name
  • string

Name of the variable.

Value
  • string

Value of the variable.

Variant

Name Type Description
Description
  • string

Description of the variant.

Id
  • string

Id of the variant.

IsControl
  • boolean

Specifies if variant is control for experiment.

Name
  • string

Name of the variant.

TitleDataOverrideLabel
  • string

Id of the TitleDataOverride to use with this variant.

TrafficPercentage
  • number

Percentage of target audience traffic that will see this variant.

Variables

Variables returned by this variant.

Error Codes

Name Code
ExperimentationExclusionGroupInsufficientCapacity 7019
ExperimentationExperimentNotFound 7002
ExperimentationExperimentRunning 7001
ExperimentationExperimentStopped 7000
ExperimentationInvalidDuration 7012
ExperimentationInvalidEndDate 7015
ExperimentationInvalidStartDate 7016
ExperimentationMaxDurationExceeded 7017
FeatureNotConfiguredForTitle 1177
SegmentNotFound 1220