Deletes a specified Source Network Address Translation (SNAT) entry.
Description
DeleteSnatEntry is an asynchronous operation. After you make a request, the ID of the request is returned but the specified SNAT entry is not deleted. The system deletes the SNAT entry in the background. You can call the DescribeNatGateways operation to query the state of the SNAT entry.
- If the SNAT entry is in the Deleting state, the system is deleting the SNAT entry. In this case, you can only query the status of the SNAT entry, and cannot perform other operations.
- If no SNAT entry is returned in the response, the SNAT entry is deleted.
If an SNAT table contains SNAT entries in the Pending state, you cannot delete any SNAT entries in the SNAT table.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DeleteSnatEntry |
The operation that you want to perform. Set the value to DeleteSnatEntry. |
RegionId | String | Yes | cn-hangzhou |
The ID of the region where the NAT gateway is deployed. You can call the DescribeRegions operation to query the most recent region list. |
SnatEntryId | String | Yes | snat-bp1vcgcf8tm0plqcg**** |
The ID of the SNAT entry that you want to delete. |
SnatTableId | String | Yes | stb-bp190wu8io1vgev80**** |
The ID of the SNAT table to which the SNAT entry belongs. |
ClientToken | String | No | 5A2CFF0E-5718-45B5-9D4D-70B3FF3898 |
The client token that is used to ensure the idempotence of the request. You can use
the client to generate the value, but you must make sure that it is unique among different
requests. Note If you do not set this parameter, the system automatically uses the request ID as
the client token. The ID of each request may be unique.
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 0ED8D006-F706-4D23-88ED-E11ED28DCAC0 |
The ID of the request. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=DeleteSnatEntry
&RegionId=cn-hangzhou
&SnatEntryId=snat-bp1vcgcf8tm0plqcg****
&SnatTableId=stb-bp190wu8io1vgev80****
&<Common request parameters>
Sample success responses
XML
format
<DeleteSnatEntryResponse>
<RequestId>0ED8D006-F706-4D23-88ED-E11ED28DCAC0</RequestId>
</DeleteSnatEntryResponse>
JSON
format
{
"RequestId": "0ED8D006-F706-4D23-88ED-E11ED28DCAC0"
}
Error codes
HttpCode | Error code | Error message | Description |
---|---|---|---|
400 | IncorretSnatEntryStatus | Some Snat entry status blocked this operation.. | The error message returned because you are not authorized to perform the specified operation. The error message returned because one or more SNAT entries in the SNAT table are in the Pending or Modifying state. |
404 | InvalidRegionId.NotFound | The specified RegionId does not exist in our records. | The error message returned because the specified region ID does not exist. |
404 | InvalidSnatEntryId.NotFound | Specified Snat entry ID does not exist | The error message returned because the specified SNAT entry does not exist. Check whether the SNAT entry is valid. |
404 | InvalidSnatTableId.NotFound | Specified SNAT table does not exist. | The error message returned because the specified SNAT table does not exist. Check whether the ID of the SNAT table is valid. |
404 | InvalidSnatEntryId.NotFound | Specified SNAT entry does not exist. | The error message returned because the specified SNAT entry does not exist. Check whether the SNAT entry is valid. |
For a list of error codes, visit the API Error Center.