Retrieves the plug-in configuration.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mse:GetPluginConfig |
get |
*Gateway
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| GatewayUniqueId |
string |
Yes |
The unique ID of the gateway. |
gw-ubuwqygbq4783gqb2y3f87q**** |
| PluginId |
integer |
Yes |
The ID of the gateway plug-in. |
123 |
| AcceptLanguage |
string |
No |
The language of the response. Valid values: zh: Chinese en: English |
zh |
Response elements
|
Parameter |
Type |
Description |
Example |
|
object |
RestResult |
||
| RequestId |
string |
The request ID. |
03A3E2F4-6804-5663-9D5D-2EC47A1***** |
| Success |
boolean |
Indicates whether the request was successful. |
true |
| Code |
integer |
The code. |
200 |
| ErrorCode |
string |
The error code. |
500 |
| HttpStatusCode |
integer |
The HTTP status code. |
200 |
| Message |
string |
The operation information. |
success |
| DynamicCode |
string |
The dynamic error code. |
code |
| DynamicMessage |
string |
The dynamic error message. |
message |
| Data |
object |
The response data. |
|
| Id |
integer |
The plug-in ID. |
1 |
| PrimaryUser |
string |
The ID of the creator. |
123 |
| Type |
integer |
The plug-in type:
|
0 |
| Category |
integer |
The category of the plug-in. 0: user-defined 1: permission authorization 2: security protection 3: transport protocol 4: traffic control 5: traffic observation |
0 |
| Name |
string |
The name of the plug-in. |
name |
| Version |
string |
The version of the plug-in. |
v1 |
| Summary |
string |
The summary of the plug-in. |
This is a plug-in. |
| SummaryEn |
string |
||
| Readme |
string |
The README description. |
read me |
| ReadmeEn |
string |
The English README description. |
read me |
| ConfigExample |
string |
The plug-in configuration example |
|
| Phase |
integer |
The execution phase of the plug-in. 0: default phase 1: authentication phase 2: authorization phase 3: statistics phase |
0 |
| Priority |
integer |
The execution priority of the plug-in. A larger value indicates a higher priority. |
1 |
| ConfigCheck |
string |
The information about the configuration check. |
\# The configuration includes the fields required for checking, such as name, age, and friends. Sample configuration: name: John age: 18 friends: - David - Anne |
| Mode |
integer |
The pattern. |
0 |
| WasmLang |
integer |
The implementation language of wasm. 0: C++ 1: TinyGo 2: Rust 3: AssemblyScript 4: Zig |
0 |
| ImageName |
string |
The image name. |
name |
| PublishState |
integer |
The publish status. |
1 |
| Status |
string |
Indicates whether the plug-in is enabled. 0: disabled 1: enabled |
1 |
| GatewayConfigList |
array |
The list of gateway plug-in configurations. |
|
|
object |
The data object. |
||
| Id |
integer |
The plug-in configuration ID. |
1 |
| GatewayId |
integer |
The gateway ID. |
1 |
| GatewayUniqueId |
string |
The unique ID of the gateway. |
gw-ubuwqygbq4783gqb2y3f87q**** |
| PluginId |
integer |
The ID of the gateway plug-in. |
1 |
| Enable |
boolean |
Indicates whether the plug-in is enabled. |
true |
| Config |
string |
The plug-in configuration. |
\# Configure a check for the required fields of the plug-in, such as name, age, and friends. Sample configuration: name: John age: 18 friends: - David - Anne |
| ConfigLevel |
integer |
The application scope of the plug-in. 0: global 1: domains 2: routes |
0 |
| ResourceList |
array |
The domains or routes that are distinguished based on ConfigLevel. |
|
|
object |
|||
| Id |
integer |
||
| Name |
string |
The domain name or route name. |
test-route |
| GmtCreate |
string |
The time when the configuration was created. |
1667309705000 |
| GmtModified |
string |
The time when the configuration was updated. |
1667309705000 |
| RouteConfigStartIndex |
integer |
The starting subscript index of the route-level rule in the GatewayConfigList. If no route-level rule exists, the value is -1 |
0 |
| DomainConfigStartIndex |
integer |
The starting subscript index of the domain-level rule in the GatewayConfigList. If no domain-level rule exists, the value is -1 |
5 |
| GatewayConfigStartIndex |
integer |
The starting subscript index of the instance-level rule in the GatewayConfigList. If no instance-level rule exists, the value is -1 |
7 |
| VersionJson |
string |
The information about the gateway plug-in version. |
Examples
Success response
JSON format
{
"RequestId": "03A3E2F4-6804-5663-9D5D-2EC47A1*****",
"Success": true,
"Code": 200,
"ErrorCode": "500",
"HttpStatusCode": 200,
"Message": "success",
"DynamicCode": "code",
"DynamicMessage": "message",
"Data": {
"Id": 1,
"PrimaryUser": "123",
"Type": 0,
"Category": 0,
"Name": "name",
"Version": "v1",
"Summary": "This is a plug-in.\n",
"SummaryEn": "",
"Readme": "read me",
"ReadmeEn": "read me",
"ConfigExample": "",
"Phase": 0,
"Priority": 1,
"ConfigCheck": "\\# The configuration includes the fields required for checking, such as name, age, and friends. Sample configuration: name: John age: 18 friends: - David - Anne\n",
"Mode": 0,
"WasmLang": 0,
"ImageName": "name",
"PublishState": 1,
"Status": "1",
"GatewayConfigList": [
{
"Id": 1,
"GatewayId": 1,
"GatewayUniqueId": "gw-ubuwqygbq4783gqb2y3f87q****",
"PluginId": 1,
"Enable": true,
"Config": "\\# Configure a check for the required fields of the plug-in, such as name, age, and friends. Sample configuration: name: John age: 18 friends: - David - Anne\n",
"ConfigLevel": 0,
"ResourceList": [
{
"Id": 0,
"Name": "test-route"
}
],
"GmtCreate": "1667309705000",
"GmtModified": "1667309705000"
}
],
"RouteConfigStartIndex": 0,
"DomainConfigStartIndex": 5,
"GatewayConfigStartIndex": 7,
"VersionJson": ""
}
}
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.