|
Parameter |
Type |
Description |
Example |
|---|---|---|---|
|
object |
The AI API configuration. |
||
| environmentId |
string |
The environment ID. |
env-xxx |
| backendScene |
string |
The publishing scenario. |
SingleService |
| autoDeploy |
boolean |
Specifies whether to automatically deploy. |
true |
| gatewayId |
string |
The gateway instance ID. |
gw-xx |
| routeBackend | Backend |
The backend service information. |
|
| gatewayInfo | GatewayInfo |
The gateway information. |
|
| mock | HttpApiMockContract |
The mock configuration. |
|
| gatewayType |
string |
The gateway type. |
API |
| customDomainIds |
array |
The list of custom domain name IDs. |
|
|
string |
The domain name ID. |
d-xxx |
|
| envDomainIds |
array |
The list of environment domain name IDs. If this parameter is not specified, all environment domain names are associated. If an empty array is specified, no environment domain names are associated. |
|
|
string |
The list of environment domain name IDs. |
d-xxx |
|
| serviceConfigs |
array |
The list of service configurations. |
|
|
object |
The existing service configuration. |
||
| serviceId |
string |
The service ID. |
svc-xxx |
| weight |
integer |
The service weight. |
100 |
| modelNamePattern |
string |
The model name matching rule. |
qwen-* |
| modelName |
string |
The model name. |
qwen-max |
| intentCode |
string |
The intent code. |
INQUIRY |
| match | HttpApiBackendMatchConditions |
The matching condition. |
|
| port |
integer |
The service port number. |
80 |
| protocol |
string |
The service protocol (HTTP/HTTPS). |
HTTP |
| gatewayServiceId |
string |
The gateway service ID. |
gw-svc-abc123 |
| name |
string |
The service display name. |
Qwen-Max-Service |
| version |
string |
The service version label. |
V2 |
| multiServiceRouteStrategy |
string |
The multi-service routing strategy type. |
ByWeight |
| observabilityRouteConfig |
object |
The observability metric routing configuration. |
|
| mode |
string |
Routing mode. |
LeastBusy |
| rateLimit |
number |
Maximum traffic ratio for a single service. |
0.8 |
| queueSize |
integer |
Queue size. |
100 |
| policyConfigs |
array |
The list of policy configurations. |
|
|
object |
The list of policy configurations. |
||
| type |
string |
Policy type. |
AiFallback |
| enable |
boolean |
Whether to enable. |
true |
| aiFallbackConfig |
object |
AiFallback policy configuration. |
|
| serviceConfigs |
array |
List of service configurations. |
|
|
object |
List of service configurations. |
||
| serviceId |
string |
Service ID. |
svc-****** |
| targetModelName |
string |
Target model name. |
gpt-4/llama3-70b |
| aiSecurityGuardConfig |
object |
Loop rules. |
|
| serviceAddress |
string |
Service endpoint specifying the network location of the backend service. |
https://api.example.com/v1 |
| checkRequest |
boolean |
Whether to enable request validation. |
true |
| checkResponse |
boolean |
Whether to enable response validation. |
true |
| checkRequestImage |
boolean |
Whether to enable image content validation in requests. |
true |
| checkResponseImage |
boolean |
Whether to enable image content validation in responses. |
true |
| requestCheckService |
string |
External service endpoint or configuration used for request validation. |
https://checker.example.com/validate-request |
| responseCheckService |
string |
External service endpoint or configuration used for response validation. |
https://checker.example.com/validate-response |
| requestImageCheckService |
string |
External service endpoint or configuration used for image content validation in requests. |
https://image-checker.example.com/scan |
| responseImageCheckService |
string |
External service endpoint or configuration used for image content validation in responses. |
https://image-checker.example.com/scan-response |
| riskAlertLevel |
string |
Risk alert level indicating the severity of content or behavior. |
low/medium/high |
| riskConfig |
array |
Loop rules. |
|
|
object |
Loop rules. |
||
| type |
string |
Policy type. |
K8S |
| level |
string |
Conflict level. Valid values:
|
Critical |
| consumerRules |
object |
Loop rules. |
|
| pattern |
string |
When type=relativeMonthly, specifies which week of the month:
|
first |
| matchType |
string |
Query match type:
|
term |
| bufferLimit |
integer |
Maximum buffer size in bytes. |
50 |
| consumerRequestCheckService |
array |
Consumer request validation services. |
|
|
object |
object |
||
| name |
string |
Name. |
API |
| requestCheckService |
string |
Request validation service. |
https://checker.example.com/validate |
| requestImageCheckService |
string |
Request image validation service. |
https://image-check.example.com/scan |
| matchType |
string |
Match type. |
exact/prefix |
| modalityType |
string |
Modality type. |
text/image |
| consumerResponseCheckService |
array |
Consumer response validation services. |
|
|
object |
object |
||
| name |
string |
Name. |
AI_API |
| responseCheckService |
string |
Response validation service. |
https://checker.example.com/validate-response |
| responseImageCheckService |
string |
Response image validation service. |
https://image-check.example.com/scan-response |
| matchType |
string |
Query match type:
|
term |
| modalityType |
string |
Modality type. |
text/image |
| consumerRiskLevel |
array |
Consumer risk levels. |
|
|
object |
object |
||
| name |
string |
Parameter name. |
APIG-UI |
| matchType |
string |
Query match type:
|
term |
| type |
string |
Backend service scenarios:
|
K8S |
| level |
string |
Conflict level. Valid values:
|
Critical |
| aiTokenRateLimitConfig |
object |
AI token rate limiting configuration. |
|
| rules |
array |
List of validation or processing rules. |
|
|
object |
List of validation or processing rules. |
||
| limitType |
string |
Rate limiting type. |
request/token |
| matchKey |
string |
Match key. |
user_id/api_path |
| matchType |
string |
Query match type:
|
term |
| matchValue |
string |
Match value. |
user123 |
| limitMode |
string |
Throttling mode. |
local |
| limitValue |
integer |
Rate limit value. |
100 |
| globalRules |
array |
Global rules. |
|
|
object |
Global rules. |
||
| limitType |
string |
Rate limiting type. |
request |
| matchKey |
string |
Match key. |
user_id |
| matchType |
string |
Query match type:
|
term |
| matchValue |
string |
Match value. |
user123 |
| limitMode |
string |
Throttling mode. |
local |
| limitValue |
integer |
Rate limit value. |
100 |
| enableGlobalRules |
boolean |
Whether to enable global rules. |
true |
| aiStatisticsConfig |
object |
||
| logRequestContent |
boolean |
||
| logResponseContent |
boolean |
||
| customDomainInfos |
array |
The list of custom domain name information. |
|
|
object |
The list of custom domain name information. |
||
| domainId |
string |
The domain name ID. |
d-cshee6dlhtgk****** |
| name |
string |
The domain name. |
hello-server.com |
| protocol |
string |
The protocol. |
HTTP |
| envDomainInfos |
array |
The list of environment domain name information. |
|
|
object |
The environment domain name information. |
||
| domainId |
string |
The domain name ID. |
|
| name |
string |
The domain name. |
|
| protocol |
string |
The protocol. |
|
| subDomains |
array |
The list of subdomain information. |
|
|
object |
The network type. |
||
| domainId |
string |
The domain name ID. |
d-csmn42um****** |
| name |
string |
The domain name. |
test |
| protocol |
string |
The protocol. |
HTTP |
| networkType |
string |
The network type. |
Intranet |
| builtinRouteNames |
array |
The list of built-in route names. |
|
|
string |
The list. |