All Products
Search
Document Center

:Make API requests

Last Updated:Jun 05, 2023

This topic describes the syntax of making Service Mesh (ASM) API requests and the responses. To make an ASM API request, you must send an HTTP GET request to the ASM endpoint and add the request parameters that correspond to the API operation being called. After you call the API operation, the system returns a response. The request and response are both encoded in UTF-8.

Request syntax

ASM API operations use the Remote Procedure Call (RPC) protocol. You can call ASM API operations by sending HTTP GET requests.

The following example shows the syntax of an ASM API request:

http://Endpoint/?Action=xx&Parameters

where:

  • Endpoint: the endpoint of the ASM API, which is servicemesh.aliyuncs.com.

  • Action: the action to be executed. For example, call the DescribeServiceMeshDetail operation to query the details of an ASM instance.

  • Version: the version number of the API. Set the value to 2020-01-11.

  • Parameters: request parameters that are separated with ampersands (&).

    Request parameters include both common request parameters and API operation-specific parameters. Common parameters include information such as the API version number and authentication information.

The following code provides an example on how to call the DescribeServiceMeshDetail operation to query the details of an ASM instance.

Note

The following code has been formatted to ease reading.

https://servicemesh.aliyuncs.com/?Action=DescribeServiceMeshDetail
&Format=xml
&Version=2020-01-11
&Signature=xxxx%xxxx%3D
&SignatureMethod=HMAC-SHA1
&SignatureNonce=15215528852396
&SignatureVersion=1.0
&AccessKeyId=key-test
&TimeStamp=2012-06-01T12:00:00Z
…