ApiProps
Properties for defining a Api
.
See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-apigateway-api
Initializer
import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkapigateway"
&alicloudroscdkapigateway.ApiProps {
ApiName: interface{},
GroupId: interface{},
RequestConfig: interface{},
ServiceConfig: interface{},
Visibility: interface{},
AllowSignatureMethod: interface{},
AppCodeAuthType: interface{},
AuthType: interface{},
ConstParameters: interface{},
Description: interface{},
DisableInternet: interface{},
ErrorCodeSamples: interface{},
FailResultSample: interface{},
ForceNonceCheck: interface{},
OpenIdConnectConfig: interface{},
RequestParameters: interface{},
ResultBodyModel: interface{},
ResultDescriptions: interface{},
ResultSample: interface{},
ResultType: interface{},
ServiceParameters: interface{},
ServiceParametersMap: interface{},
SystemParameters: interface{},
Tags: *[]github.com/alibabacloud-go/ros-cdk/alicloudroscdkapigateway.RosApi.TagsProperty,
WebSocketApiType: interface{},
}
Properties
Name | Type | Description |
---|---|---|
ApiName |
interface{} |
Property apiName: The name of the API.It must be 4 to 128 characters in length, and can contain letters, digits, underscores (_), dashes (-), spaces and dots (.), It must start with a letter. |
GroupId |
interface{} |
Property groupId: The id of the Group. |
RequestConfig |
interface{} |
Property requestConfig: The configuration of the request. |
ServiceConfig |
interface{} |
Property serviceConfig: The configuration of the service. |
Visibility |
interface{} |
Property visibility: Whether to make the API public. |
AllowSignatureMethod |
interface{} |
Property allowSignatureMethod: If the AuthType is APP authentication, you need to pass this value to specify the signature algorithm. |
AppCodeAuthType |
interface{} |
Property appCodeAuthType: When AuthType is APP authentication, the optional values are as follows: If not passed, the default value is DEFAULT: DEFAULT: Default (set by group). |
AuthType |
interface{} |
Property authType: Type of authorization of the API . |
ConstParameters |
interface{} |
Property constParameters: The const parameters. |
Description |
interface{} |
Property description: Description of the API, less than 180 characters. |
DisableInternet |
interface{} |
Property disableInternet: Set DisableInternet to true, only support intranet to call API. |
ErrorCodeSamples |
interface{} |
Property errorCodeSamples: The Error Code samples. |
FailResultSample |
interface{} |
Property failResultSample: The sample of the fail result. |
ForceNonceCheck |
interface{} |
Property forceNonceCheck: Set ForceNonceCheck to true, compulsorily check X-Ca-Nonce when requesting, this is the unique identifier of the request, generally using UUID to identify. |
OpenIdConnectConfig |
interface{} |
Property openIdConnectConfig: The configuration of the open id. |
RequestParameters |
interface{} |
Property requestParameters: The request parameters. |
ResultBodyModel |
interface{} |
Property resultBodyModel: The return result of the API. |
ResultDescriptions |
interface{} |
Property resultDescriptions: The return description of the API. |
ResultSample |
interface{} |
Property resultSample: The sample of the result. |
ResultType |
interface{} |
Property resultType: The format of service's response, "JSON", "TEXT", "BINARY", "XML", "HTML" or "PASSTHROUGH". |
ServiceParameters |
interface{} |
Property serviceParameters: The service parameters. |
ServiceParametersMap |
interface{} |
Property serviceParametersMap: The mapping relation between (request parameters\const parameters\system parameters) and service parameters. |
SystemParameters |
interface{} |
Property systemParameters: The system parameters. |
Tags |
*[]TagsProperty |
Property tags: Tags to attach to instance. |
WebSocketApiType |
interface{} |
Property webSocketApiType: The type of the two-way communication API. |
ApiName
Required
ApiName interface{}
- Type: interface{}
Property apiName: The name of the API.It must be 4 to 128 characters in length, and can contain letters, digits, underscores (_), dashes (-), spaces and dots (.), It must start with a letter.
GroupId
Required
GroupId interface{}
- Type: interface{}
Property groupId: The id of the Group.
RequestConfig
Required
RequestConfig interface{}
- Type: interface{}
Property requestConfig: The configuration of the request.
ServiceConfig
Required
ServiceConfig interface{}
- Type: interface{}
Property serviceConfig: The configuration of the service.
Visibility
Required
Visibility interface{}
- Type: interface{}
Property visibility: Whether to make the API public.
"PUBLIC" or "PRIVATE".
AllowSignatureMethod
Optional
AllowSignatureMethod interface{}
- Type: interface{}
Property allowSignatureMethod: If the AuthType is APP authentication, you need to pass this value to specify the signature algorithm.
If you do not specify this parameter, the default value HmacSHA256 is used. Valid values: HmacSHA256 HmacSHA1,HmacSHA256
AppCodeAuthType
Optional
AppCodeAuthType interface{}
- Type: interface{}
Property appCodeAuthType: When AuthType is APP authentication, the optional values are as follows: If not passed, the default value is DEFAULT: DEFAULT: Default (set by group).
DISABLE: Not allowed HEADER: Allow AppCode header authentication HEADER_QUERY: Allow AppCode header and query authentication
AuthType
Optional
AuthType interface{}
- Type: interface{}
Property authType: Type of authorization of the API .
"APP","ANONYMOUS", or "APPOPENID"
ConstParameters
Optional
ConstParameters interface{}
- Type: interface{}
Property constParameters: The const parameters.
Description
Optional
Description interface{}
- Type: interface{}
Property description: Description of the API, less than 180 characters.
DisableInternet
Optional
DisableInternet interface{}
- Type: interface{}
Property disableInternet: Set DisableInternet to true, only support intranet to call API.
Set DisableInternet to false, then the call is not restricted.
ErrorCodeSamples
Optional
ErrorCodeSamples interface{}
- Type: interface{}
Property errorCodeSamples: The Error Code samples.
FailResultSample
Optional
FailResultSample interface{}
- Type: interface{}
Property failResultSample: The sample of the fail result.
ForceNonceCheck
Optional
ForceNonceCheck interface{}
- Type: interface{}
Property forceNonceCheck: Set ForceNonceCheck to true, compulsorily check X-Ca-Nonce when requesting, this is the unique identifier of the request, generally using UUID to identify.
The API gateway will verify the validity of this parameter after receiving this parameter. The same value can only be used once within 15 minutes. It can effectively prevent API replay attacks. Set ForceNonceCheck to false, then no check.
OpenIdConnectConfig
Optional
OpenIdConnectConfig interface{}
- Type: interface{}
Property openIdConnectConfig: The configuration of the open id.
RequestParameters
Optional
RequestParameters interface{}
- Type: interface{}
Property requestParameters: The request parameters.
ResultBodyModel
Optional
ResultBodyModel interface{}
- Type: interface{}
Property resultBodyModel: The return result of the API.
ResultDescriptions
Optional
ResultDescriptions interface{}
- Type: interface{}
Property resultDescriptions: The return description of the API.
ResultSample
Optional
ResultSample interface{}
- Type: interface{}
Property resultSample: The sample of the result.
ResultType
Optional
ResultType interface{}
- Type: interface{}
Property resultType: The format of service's response, "JSON", "TEXT", "BINARY", "XML", "HTML" or "PASSTHROUGH".
Default is "JSON".
ServiceParameters
Optional
ServiceParameters interface{}
- Type: interface{}
Property serviceParameters: The service parameters.
ServiceParametersMap
Optional
ServiceParametersMap interface{}
- Type: interface{}
Property serviceParametersMap: The mapping relation between (request parameters\const parameters\system parameters) and service parameters.
SystemParameters
Optional
SystemParameters interface{}
- Type: interface{}
Property systemParameters: The system parameters.
Tags
Optional
Tags *[]TagsProperty
- Type: *[]TagsProperty
Property tags: Tags to attach to instance.
Max support 20 tags to add during create instance. Each tag with two properties Key and Value, and Key is required.
WebSocketApiType
Optional
WebSocketApiType interface{}
- Type: interface{}
Property webSocketApiType: The type of the two-way communication API.
COMMON: common API REGISTER: registered API UNREGISTER: unregistered API NOTIFY: downstream notification API