Updated on 2024-01-09 GMT+08:00

Deleting predefined tags

Function

This API is used to deletes predefined tags. This API supports idempotency and batch data processing.

Calling Method

For details, see Calling APIs.

URI

POST /v1.0/predefine_tags/action

Request Parameters

Table 1 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token. Note: TMS is a global service. Therefore, when calling the IAM service to obtain user tokens, set the scope field to domain. The value of X-Subject-Token in the response header is the user token.

Table 2 Request body parameters

Parameter

Mandatory

Type

Description

action

Yes

String

Specifies the operation (case sensitive). The value is delete.

tags

Yes

Array of PredefineTagRequest objects

Tag list.

Table 3 PredefineTagRequest

Parameter

Mandatory

Type

Description

key

Yes

String

Specifies the tag key. The value can contain up to 36 characters including letters, digits, hyphens (-), and underscores (_).

value

Yes

String

Specifies the tag value.The value can contain up to 43 characters including letters, digits, periods (.), hyphens (-), and underscores (_). It can be an empty string.

Response Parameters

Status code: 400

Table 4 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 5 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 401

Table 6 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 7 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 403

Table 8 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 9 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 404

Table 10 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 11 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 405

Table 12 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 13 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 406

Table 14 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 15 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 409

Table 16 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 17 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 410

Table 18 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 19 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 412

Table 20 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 21 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 429

Table 22 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 23 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 500

Table 24 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 25 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 501

Table 26 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 27 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Status code: 503

Table 28 Response body parameters

Parameter

Type

Description

error

RespErrorMessage object

Response error information.

Table 29 RespErrorMessage

Parameter

Type

Description

error_code

String

Request error code.

error_msg

String

Error message

Example Requests

Deleting predefined tags

POST https://{Endpoint}/v1.0/predefine_tags/action

{
  "action" : "delete",
  "tags" : [ {
    "key" : "ENV1",
    "value" : "DEV1"
  }, {
    "key" : "ENV2",
    "value" : "DEV2"
  } ]
}

Example Responses

None

Status Codes

Status Code

Description

204

No Content

400

Bad Request

401

Unauthorized

403

Forbidden

404

Not Found

405

Method Not Allowed

406

Not Acceptable

409

Conflict

410

Gone

412

Precondition Failed

429

Too Many Requests

500

Internal Server Error

501

Not Implemented

503

Service Unavailable

Error Codes

See Error Codes.