Stopping ECSs in Batches

Function

This interface is used to stop ECSs in batches based on specified ECS IDs.

URI

  • URI format

    POST /v1/{project_id}/cloudservers/action

  • Parameter description

    Name

    Mandatory

    Description

    project_id

    Yes

    Specifies the tenant ID.

Request

  • Parameter description
    NOTE:

    In the request parameters, the request for stopping the ECS must be issued with field os-stop, as shown in the example request.

    Name

    Mandatory

    Type

    Description

    os-stop

    Yes

    Dictionary data structure [1]

    Specifies the operation to stop the ECS.

[1] os-stop field data structure description

Name

Mandatory

Type

Description

servers

Yes

List data structure [2]

Specifies the list of the ECS IDs.

type

No

String

Specifies the ECS stop type.

SOFT: normal ECS stop (default)

HARD: forcible ECS stop

[2] servers field data structure description

Name

Mandatory

Type

Description

id

Yes

String

Specifies the ECS ID.

  • Example request
    {
        "os-stop": {
            "type":"HARD",
            "servers": [
                {
                    "id": "616fb98f-46ca-475e-917e-2563e5a8cd19"
                },
                {
                    "id": "726fb98f-46ca-475e-917e-2563e5a8cd20"
                }
    
            ]
        }
    }

Response

See Response.

Returned Values

See Returned Values.

Registration