Find answers to common questions about Cloud Control API, including how to obtain service codes, resource attributes, and request paths.
Overview
-
Where can I find the resource attributes for the CreateResource and UpdateResource operations?
-
How do I specify the requestPath parameter for resource management API calls?
Finding service and resource type codes
-
Call the ListProducts and ListResourceTypes operations to retrieve the service code and resource type code in real time.
-
Go to OpenAPI Explorer to look up the service code and resource type code.
Finding resource attributes
-
Call the ListResourceTypes operation to retrieve resource metadata and find the resource attribute specifications.
-
Go to OpenAPI Explorer to look up the required resource attributes for a specific operation.
Specifying the requestPath parameter
-
Construct the request path by combining the service code and the resource type code as described in the API documentation.
-
Alternatively, go to OpenAPI Explorer to view the exact request path.
For example, consider a VPC resource. In OpenAPI Explorer, on the CreateResource page, the requestPath parameter is set to /api/v1/providers/Aliyun/products/VPC/resources/VPC. In this path, products/VPC maps to the service code and resources/VPC maps to the resource type code. You can copy this request path directly from the sample code on the right.