Authorizes a Smart Access Gateway (SAG) instance to communicate with a Cloud Connect Network (CCN) instance that belongs to another Alibaba Cloud account.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | GrantSagInstanceToCcn |
The operation that you want to perform. Set the value to GrantSagInstanceToCcn. |
RegionId | String | Yes | cn-shanghai |
The ID of the region where the SAG instance is deployed. |
SmartAGId | String | Yes | sag-tzirqx07bvcngm**** |
The ID of the SAG instance. |
CcnInstanceId | String | Yes | ccn-n2935s1mnwv8i***** |
The ID of the CCN instance. |
CcnUid | Long | Yes | 1210123456123456 |
The ID of the Alibaba Cloud account to which the CCN instance belongs. |
GrantTrafficService | Boolean | No | true |
Specifies whether to grant the CCN instance permissions to manage network traffic from the SAG instance. After the CCN instance is granted the permissions, the CCN instance can redirect the network traffic sent from the SAG instance to the Internet to Cloud Security Access Service (CSAS) for security audit.
Note If you set the value to true and the SAG instance connected to the CCN instance has
the secure rerouting feature enabled, you cannot revoke the permissions.
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 6E1674AC-083C-4031-B047-7A66E418E0C6 |
The ID of the request. |
InstanceId | String | sgc-6z21oj0vjjrx6s**** |
The ID of the permission policy. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=GrantSagInstanceToCcn
&RegionId=cn-shanghai
&SmartAGId=sag-tzirqx07bvcngm****
&CcnInstanceId=ccn-n2935s1mnwv8i*****
&CcnUid=1210123456123456
&GrantTrafficService=true
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<GrantSagInstanceToCcnResponse>
<RequestId>6E1674AC-083C-4031-B047-7A66E418E0C6</RequestId>
<InstanceId>sgc-6z21oj0vjjrx6s****</InstanceId>
</GrantSagInstanceToCcnResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "6E1674AC-083C-4031-B047-7A66E418E0C6",
"InstanceId" : "sgc-6z21oj0vjjrx6s****"
}
Error codes
HttpCode | Error code | Error message | Description |
---|---|---|---|
400 | CCN.InvalidUid | The specified CCN user ID is invalid. | The error message returned because the specified UID of the Alibaba Cloud account to which the specified CCN instance belongs is invalid. |
400 | CCN.InvalidId | You must specify the CCN instance ID. | The error message returned because the specified CCN instance ID does not exist. |
400 | SAG.InstanceIdEmpty | You must specify the SAG instance ID. | The error message returned because the ID of the SAG instance is not set. |
400 | SAG.InstanceNoFound | The specified SAG instance does not exist. | The error message returned because the specified SAG instance does not exist. |
400 | SAG.GrantDuplicated | You have authorized another CCN instance to bind to the specified SAG instance. Revoke the authorization first. | The error message returned because the specified SAG instance is already associated with another CCN instance. Disassociate the SAG instance from the CCN instance first. |
For a list of error codes, visit the API Error Center.