To send a Real-Time Communication (RTC) API request, you must send an HTTP GET request to the RTC endpoint. You must add the request parameters that correspond to the API operation that is called. After you call the API operation, the system returns a response.
RTC API operations use the Remote Procedure Call (RPC) protocol. You can call RTC API operations by sending HTTP GET requests. You can also send API requests by using HTTP or HTTPS. For higher security, we recommend that you send API requests by using HTTPS. All requests and responses are UTF-8 encoded. The following example shows the request syntax:
https://Endpoint/?Action=xx&Version=xx&Parameters
- Endpoint: The endpoint of RTC API is rtc.aliyuncs.com.
- Action: the operation that you want to perform. For example, you can set the parameter to DeleteChannel to delete a channel.
- Version: the version number of RTC API. The current version number of RTC API is 2018-01-11.
- Parameters: the request parameters for the operation. Separate multiple parameters with ampersands (
&). Request parameters include both common parameters and operation-specific parameters. Common parameters include information such as the API version number and identity verification information. For more information, see Common parameters.
The following sample code provides an example on the request syntax of calling the DeleteChannel operation.
Note The following sample code has been formatted to improve readability.
https://rtc.aliyuncs.com/?Action=DeleteChannel
&AppId=a2h1****
&ChannelId=jzu****
&Format=XML
&AccessKeyId=testid
&SignatureMethod=HMAC-SHA1
&SignatureNonce=3ee8c1b8-83d3-44af-a94f-4e0ad82fd6cf
&Version=2018-01-11
&SignatureVersion=1.0
&Signature=%1h%3D****
&Timestamp=2017-03-29T09%3A22%3A32Z
...
该文章对您有帮助吗?