Creates a test scenario.

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

POST /v4/openapi/app-groups/[appGroupIdentity]/scenes HTTP/1.1

Request parameters

Parameter Type Position Required Example Description
appGroupIdentity String Path Yes my_app_group_name

The name of the application.

Request body

Parameter

Type

Required

Example

Description

name

String

Yes

"kevintest22"

The name of the test scenario.

values[]

String

Yes

"kevintest22"

The tag of the test scenario.

Response parameters

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

The ID of the request.

result Struct

The return result.

created Integer 1589012351

The time when the test scenario was created.

id String 20405

The ID of the test group.

name String kevintest_2020-5-7_15:21:48

The name of the test group.

status Integer 1

The status of the test scenario. Valid values:

  • 0: not in effect
  • 1: in effect
updated Integer 1589012351

The time when the test scenario was last modified.

values List [ "kevintest" ]

The tag of the test scenario.

Examples

Sample requests

POST /v4/openapi/app-groups/myappgroupname/scenes 

{
    "values": [
        "kevintest"
        ],
    "name": "kevintest2020-5-7_15:21:48"
}

Sample success responses

XML format

<requestId>D77D0DAF-790D-F5F5-A9C0-133738165014</requestId>
<result>
    <id>20405</id>
    <name>kevintest_2020-5-7_15:21:48</name>
    <status>1</status>
    <created>1589012351</created>
    <updated>1589012351</updated>
    <values>kevintest</values>
</result>

JSON format

{
    "requestId": "D77D0DAF-790D-F5F5-A9C0-133738165014",
    "result": {
        "id": 20405,
        "name": "kevintest_2020-5-7_15:21:48",
        "status": 1,
        "created": 1589012351,
        "updated": 1589012351,
        "values": "kevintest"
    }
}

Error codes

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