Updated on 2025-12-31 GMT+08:00

Querying Project Tags

Function

This API is used to query project tags.

Calling Method

For details, see Calling APIs.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.

  • If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

    Action

    Access Level

    Resource Type (*: required)

    Condition Key

    Alias

    Dependencies

    cts:tag:listForProject

    List

    -

    -

    -

    -

URI

GET /v3/{project_id}/{resource_type}/tags

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID.

resource_type

Yes

String

Resource type. The value is cts-tracker.

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

limit

No

Integer

Maximum records that can be returned. The value ranges from 1 to 200 (default).

marker

No

String

Pagination parameter. You can use the marker value returned in the previous request as the number of the first page of records to return in this request.

Request Parameters

None

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

tags

Array of TmsTags objects

Tag list.

page_info

PageInfo object

Pagination parameter.

Table 4 TmsTags

Parameter

Type

Description

key

String

Tag key. A tag key contains a maximum of 128 Unicode characters. It can contain letters, digits, spaces, and special characters _.:=+-@. It cannot start or end with a space.

values

Array of strings

Value list.

Table 5 PageInfo

Parameter

Type

Description

current_count

Integer

Number of keys on the current page.

next_marker

String

The marker value of the next page.

Example Requests

None

Example Responses

Status code: 200

Request succeeded.

{
  "tags" : [ {
    "key" : "key1",
    "values" : [ "value1", "value2" ]
  }, {
    "key" : "key2",
    "values" : [ "value1", "value2" ]
  } ],
  "page_info" : {
    "current_count" : "200",
    "next_marker" : "xxx"
  }
}

Status Codes

Status Code

Description

200

Request succeeded.

Error Codes

See Error Codes.