Updated on 2024-06-20 GMT+08:00

Querying Tenant Resource Information

Function

This API is used to query tenant resource information.

URI

GET /v1/resources

Table 1 Query parameters

Parameter

Mandatory or Not

Type

Description

resource_id_list

No

Array

Resource ID list

provider

Yes

String

Specifies the cloud service name.

type

Yes

String

Resource type name

limit

Yes

Integer

Maximum number of returned records. The maximum value is 100.

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 2 Response body parameters

Parameter

Type

Description

data

Array of data objects

Specifies resource list

Table 3 data

Parameter

Type

Description

id

String

Resource ID allocated by CMDB.

resource_id

String

ID of the resource allocated by the cloud service.

name

String

Resource name

provider

String

Specifies the cloud service name.

type

String

Resource type

project_id

String

Project I in OpenStack

region_id

String

region ID

ep_id

String

The enterprise project ID

tags

Map<String,String>

Resource tag

properties

Map<String,Object>

Resource attribute details

agent_id

String

ID allocated by the UniAgent

Status code: 400

Table 4 Response body parameters

Parameter

Type

Description

error_code

String

Error code

Minimum length: 8 characters

Maximum length: 36 characters

error_msg

String

Error description

Minimum length: 2 characters

Maximum length: 512 characters

Request Example

None

Response Example

None

Status Code

Status Code

Description

200

resource info

400

Error response