Modifies a test.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation uses only the common request headers. For more information, see Common request parameters.

Request syntax

PUT /v4/openapi/app-groups/[appGroupIdentity]/scenes/[sceneId]/groups/[groupId]/experiments/[experimentId] HTTP/1.1

Request parameters

Parameter Type Position Required Example Description
appGroupIdentity String Path Yes "my_app_group_name"

The name of the application.

experimentId Integer Path Yes 12889

The ID of the test.

groupId Integer Path Yes 13467

The ID of the test group.

sceneId Integer Path Yes 20404

The ID of the test scenario.

Request body

Parameter

Type

Required

Example

Description

name

String

No

"my_test"

The name of the test.

traffic

Integer

No

30

The percentage of traffic that is routed to the test.

online

Boolean

No

true

Specifies whether the test takes effect.

params

Object

No

The parameters of the test.

Response parameters

Parameter Type Example Description
requestId String D77D0DAF-790D-F5F5-A9C0-133738165014

The ID of the request.

result Struct

The details of the test.

created Integer 1588842080

The time when the test was created.

id String 12888

The ID of the test.

name String test1

The name of the test.

online Boolean true

The status of the test. Valid values:

  • true: in effect
  • false: not in effect
params Map {}

The parameters of the test.

traffic Integer 30

The percentage of traffic that is routed to the test.

Value values: 0 to 100.

updated Integer 1588842080

The time when the test was last modified.

Examples

Sample requests

PUT /v4/openapi/app-groups/my_app_group_name/scenes/20404/groups/13466/experiments/12889

{
  "name": "test333",
  "traffic": 40,
  "params": {
    "firstFormulaName": "default"
  }
}

Sample success responses

XML format

<requestId>D77D0DAF-790D-F5F5-A9C0-133738165014</requestId>
<result>
    <id>12889</id>
    <name>test333</name>
    <params>
        <firstFormulaName>default</firstFormulaName>
    </params>
    <created>1589017860</created>
    <updated>1589018211</updated>
    <online>true</online>
    <traffic>40</traffic>
</result>

JSON format

{
    "requestId": "D77D0DAF-790D-F5F5-A9C0-133738165014",
    "result": {
        "id": 12889,
        "name": "test333",
        "params": {
            "firstFormulaName": "default"
        },
        "created": 1589017860,
        "updated": 1589018211,
        "online": true,
        "traffic": 40
    }
}

Error codes

For a list of error codes, visit the API Error Center.