Domain name for API request: ga2.intl.tencentcloudapi.com.
Create a layer-7 forwarding policy.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: CreateForwardingPolicy. |
| Version | Yes | String | Common Params. The value used for this API: 2025-01-15. |
| Region | No | String | Common Params. This parameter is not required. |
| GlobalAcceleratorId | Yes | String | Global acceleration instance ID. |
| ListenerId | Yes | String | Listener ID. |
| Host | Yes | String | Domain name. Parameter format: format, must meet the regular expression: ^(a-z0-9?.)+[a-z]{2,}$ Input limit: length range is 1-80. |
| Parameter Name | Type | Description |
|---|---|---|
| TaskId | String | Asynchronous task ID. |
| ForwardingPolicyId | String | Layer-7 forwarding policy ID. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: ga2.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateForwardingPolicy
<Common request parameters>
{
"GlobalAcceleratorId": "ga-80bzejka",
"ListenerId": "lsr-nd3qmz7h",
"Host": "www.aaa.com"
}
{
"Response": {
"RequestId": "8306a684-0b45-4933-b8b5-eeac953fa4fa",
"TaskId": "9f4180a9-80e4-4e74-a5ea-df9fee4b0aef",
"ForwardingPolicyId": "dm-3vfx7nnq"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| InvalidParameterValue.Empty | Parameter %(parameter)s cannot be empty. |
| InvalidParameterValue.ForwardingPolicyHostConflict | Layer-7 forwarding policy domain name duplicates an existing one. |
| InvalidParameterValue.InstanceMismatch | The instance object %(value)s has a mismatched relationship. |
| InvalidParameterValue.TooLong | Parameter value %(value)s length cannot be greater than %(max_size)s. |
| UnsupportedOperation.InstanceNotRunning | The instance is not in the running state. The current operation is not supported. |
| UnsupportedOperation.InstanceStateNotAllowedOperate | Current instance status does not allow this operation. |
| UnsupportedOperation.TransportLayerUnsupportedOperateForwardingPolicy | Layer-4 listeners do not support creation of forwarding policies. |
Esta página foi útil?
Você também pode entrar em contato com a Equipe de vendas ou Enviar um tíquete em caso de ajuda.
comentários