Queries the gateway route list.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mse:ListGatewayRoute |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| PageNumber |
integer |
No |
Page number. |
1 |
| PageSize |
integer |
No |
Number of instances displayed per page (currently not in effect, queries all instances by default). |
10 |
| OrderItem |
string |
No |
Sorting property. |
GmtCreate |
| DescSort |
boolean |
No |
Sorting. This field is currently unavailable and being deprecated. |
false |
| FilterParams |
object |
No |
Filter conditions in the format {"key1":"value1"}. |
|
| GatewayId |
integer |
No |
Gateway ID. |
81 |
| Name |
string |
No |
Route name. |
test |
| Status |
integer |
No |
Route status:
|
1 |
DefaultServiceId
deprecated
|
integer |
No |
Default service ID. |
1 |
| RouteOrder |
integer |
No |
Order (unused). |
1 |
| DomainId |
integer |
No |
Domain ID. |
284 |
| GatewayUniqueId |
string |
Yes |
Gateway unique identifier ID. |
gw-30a0106924c94bca8712ec4e79fc5acc |
| DomainName |
string |
No |
Associated domain |
*.alites.com |
| Path |
string |
No |
Route path. |
/test |
| AcceptLanguage |
string |
No |
Language type for returned information:
|
zh |
Response parameters
|
Parameter |
Type |
Description |
Example |
|
object |
Data structure. |
||
| RequestId |
string |
Request ID. |
83F02EAB-ECDF-55C6-B332-8649E5E7AF2C |
| HttpStatusCode |
integer |
HTTP status code. |
200 |
| Message |
string |
Error message. |
You are not authorized to perform this operation. |
| Code |
integer |
Code. |
200 |
| Success |
boolean |
Request result, with the following values:
|
true |
| Data |
object |
Returned data. |
|
| TotalSize |
integer |
Total number of entries. |
36 |
| PageNumber |
integer |
Page number. |
11 |
| PageSize |
integer |
Page size. |
10 |
| Result |
array |
Data structure. |
|
|
object |
Return collection. |
||
| Id |
integer |
Route ID. |
47 |
| Name |
string |
Name. |
test |
| GatewayUniqueId |
string |
Gateway unique identifier. |
gw-cf0e7f52ecc7429dbc7ba4d5e3656100 |
| GatewayId |
integer |
Gateway ID. |
496 |
| Status |
integer |
Status. |
2 |
| RouteOrder |
integer |
Order |
1 |
| DefaultServiceName |
string |
Default service name. |
test |
| DefaultServiceId |
integer |
Default service ID. |
1 |
| Predicates |
string |
Matching rules |
{\"PathPredicates\":{\"Path\":\"/rpc/compute \",\"Type\":\"PRE\",\"IgnoreCase\":true}} |
| RoutePredicates |
object |
Matching rules |
|
| PathPredicates |
object |
Route Path matching. |
|
| Path |
string |
Node path. |
/getIp |
| Type |
string |
Matching type. |
PRE |
| IgnoreCase |
boolean |
Ignore case |
true |
| MethodPredicates |
array |
HTTP method matching |
|
|
string |
Method |
GET |
|
| HeaderPredicates |
array |
Header matching |
|
|
object |
Header list |
||
| Key |
string |
Header KEY |
userid |
| Value |
string |
Matching value |
test |
| Type |
string |
Matching type |
PRE |
| QueryPredicates |
array |
Parameter matching |
|
|
object |
Parameter list |
||
| Key |
string |
Parameter name |
userid |
| Value |
string |
Matching value |
test |
| Type |
string |
Matching type |
PRE |
| GmtCreate |
string |
Creation time. |
2022-01-25T07:14:01.817+0000 |
| GmtModified |
string |
Modification time |
2022-01-07 18:07:57 |
| Services |
string |
Service. |
[] |
| RouteServices |
array |
Service. |
|
|
object |
Service list |
||
| ServiceId |
integer |
Service ID |
1563 |
| ServiceName |
string |
Service name. |
hu |
| Percent |
integer |
Weight percentage |
11 |
| Version |
string |
Service version. |
v1 |
| Name |
string |
Name. |
test |
| SourceType |
string |
Source type |
MSE |
| Namespace |
string |
Namespace. |
default |
| GroupName |
string |
Service group name. |
api |
| AgreementType |
string |
Protocol Type. |
DUBBO |
| HttpDubboTranscoder |
object |
Dubbo protocol conversion body. |
|
| DubboServiceName |
string |
Dubbo service name. |
org.apache.dubbo.samples.basic.api.DemoService |
| DubboServiceVersion |
string |
Dubbo service version. |
0.0.0 |
| MothedMapList |
array |
Dubbo forwarding rule list. |
|
|
object |
Method mapping body. |
||
| DubboMothedName |
string |
Dubbo method name. |
sayHello |
| HttpMothed |
string |
Http method. Note
Supported HTTP method parameter values.
|
ALL_GET |
| Mothedpath |
string |
Method matching path. |
/mytestzbk/sayhello |
| PassThroughAllHeaders |
string |
Header pass-through type. Note
Pass-through type enumeration values.
|
PASS_NOT |
| PassThroughList |
array |
Specified pass-through Header list. |
|
|
string |
Specified Header pass-through value. |
x-forward |
|
| ParamMapsList |
array |
Parameter mapping list. |
|
|
object |
Parameter mapping body. |
||
| ExtractKeySpec |
string |
Input parameter position. Note
Input parameter position enumeration values.
|
ALL_QUERY_PARAMETER |
| ExtractKey |
string |
Input parameter extraction Key. |
name |
| MappingType |
string |
Backend parameter type. |
java.lang.String |
| DubboServiceGroup |
string |
Dubbo service group. |
service group |
| ServicePort |
integer |
Service port. |
20880 |
| HealthStatus |
string |
Health status
|
Health |
| UnhealthyEndpoints |
array |
Unhealthy Endpoint list |
|
|
string |
Unhealthy Endpoint |
192.168.1.2 |
|
| DomainId |
integer |
Domain ID. |
265 |
| DomainName |
string |
Domain name. |
y.com |
| DestinationType |
string |
Destination type. |
Single |
| DirectResponse |
object |
Mock configuration |
|
| Code |
integer |
Response code. |
200 |
| Body |
string |
Mock return value |
hello |
| DomainIdList |
array |
Domain list. |
|
|
integer |
Domain ID |
123 |
|
| DomainNameList |
array |
Domain name list. |
|
|
string |
Domain name |
test.com |
|
| Redirect |
object |
Redirection |
|
| Code |
integer |
Response code. |
200 |
| Host |
string |
Redirect hostname |
test.com |
| Path |
string |
Path. |
/test |
| Type |
string |
Route type |
Op |
| Comment |
object |
Route comment (ingress) |
|
| Status |
string |
Status. |
error |
| EnableWaf |
string |
Whether to enable WAF |
false |
| Fallback |
boolean |
Whether to enable Fallback service. |
true |
| FallbackServices |
array |
Fallback service. |
|
|
object |
|||
| ServiceId |
integer |
Service ID. |
353 |
| ServiceName |
string |
Service name. |
service name |
| Percent |
integer |
Weight percentage. |
100 |
| Version |
string |
Service version. |
v1 |
| Name |
string |
Name. |
name |
| SourceType |
string |
Source type. |
MSE |
| Namespace |
string |
Service namespace. |
Namespace |
| GroupName |
string |
Service group name. |
test |
| AgreementType |
string |
Protocol Type. |
DUBBO |
| ServicePort |
integer |
Service port. |
8848 |
| DynamicRoute |
boolean |
Whether to enable dynamic routing |
Examples
Success response
JSON format
{
"RequestId": "83F02EAB-ECDF-55C6-B332-8649E5E7AF2C",
"HttpStatusCode": 200,
"Message": "You are not authorized to perform this operation.",
"Code": 200,
"Success": true,
"Data": {
"TotalSize": 36,
"PageNumber": 11,
"PageSize": 10,
"Result": [
{
"Id": 47,
"Name": "test",
"GatewayUniqueId": "gw-cf0e7f52ecc7429dbc7ba4d5e3656100",
"GatewayId": 496,
"Status": 2,
"RouteOrder": 1,
"DefaultServiceName": "test",
"DefaultServiceId": 1,
"Predicates": "{\\\"PathPredicates\\\":{\\\"Path\\\":\\\"/rpc/compute \\\",\\\"Type\\\":\\\"PRE\\\",\\\"IgnoreCase\\\":true}}",
"RoutePredicates": {
"PathPredicates": {
"Path": "/getIp",
"Type": "PRE",
"IgnoreCase": true
},
"MethodPredicates": [
"GET"
],
"HeaderPredicates": [
{
"Key": "userid",
"Value": "test",
"Type": "PRE"
}
],
"QueryPredicates": [
{
"Key": "userid",
"Value": "test",
"Type": "PRE"
}
]
},
"GmtCreate": "2022-01-25T07:14:01.817+0000",
"GmtModified": "2022-01-07 18:07:57",
"Services": "[]",
"RouteServices": [
{
"ServiceId": 1563,
"ServiceName": "hu",
"Percent": 11,
"Version": "v1",
"Name": "test",
"SourceType": "MSE",
"Namespace": "default",
"GroupName": "api",
"AgreementType": "DUBBO",
"HttpDubboTranscoder": {
"DubboServiceName": "org.apache.dubbo.samples.basic.api.DemoService",
"DubboServiceVersion": "0.0.0",
"MothedMapList": [
{
"DubboMothedName": "sayHello",
"HttpMothed": "ALL_GET",
"Mothedpath": "/mytestzbk/sayhello",
"PassThroughAllHeaders": "PASS_NOT",
"PassThroughList": [
"x-forward"
],
"ParamMapsList": [
{
"ExtractKeySpec": "ALL_QUERY_PARAMETER",
"ExtractKey": "name",
"MappingType": "java.lang.String"
}
]
}
],
"DubboServiceGroup": "service group"
},
"ServicePort": 20880,
"HealthStatus": "Health",
"UnhealthyEndpoints": [
"192.168.1.2"
]
}
],
"DomainId": 265,
"DomainName": "y.com",
"DestinationType": "Single",
"DirectResponse": {
"Code": 200,
"Body": "hello"
},
"DomainIdList": [
123
],
"DomainNameList": [
"test.com"
],
"Redirect": {
"Code": 200,
"Host": "test.com",
"Path": "/test"
},
"Type": "Op",
"Comment": {
"Status": "error"
},
"EnableWaf": "false",
"Fallback": true,
"FallbackServices": [
{
"ServiceId": 353,
"ServiceName": "service name",
"Percent": 100,
"Version": "v1",
"Name": "name",
"SourceType": "MSE\n",
"Namespace": "Namespace",
"GroupName": "test",
"AgreementType": "DUBBO",
"ServicePort": 8848
}
],
"DynamicRoute": true
}
]
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IllegalRequest | Invalid request:%s | Invalid request: %s |
| 400 | InvalidParameter | Parameter error:%s | Request parameter error: %s |
| 500 | InternalError | Console error. Try again later:%s | Console error. Try again later: %s |
| 403 | NoPermission | You are not authorized to perform this operation:%s | You do not have the permission to use this interface:%s |
| 404 | NotFound | Not found:%s | The resource does not exist:%s |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.