Create Route
| apigatewayv2_create_route | R Documentation |
Creates a Route for an API¶
Description¶
Creates a Route for an API.
Usage¶
apigatewayv2_create_route(ApiId, ApiKeyRequired, AuthorizationScopes,
AuthorizationType, AuthorizerId, ModelSelectionExpression,
OperationName, RequestModels, RequestParameters, RouteKey,
RouteResponseSelectionExpression, Target)
Arguments¶
ApiId[required] The API identifier.
ApiKeyRequiredSpecifies whether an API key is required for the route. Supported only for WebSocket APIs.
AuthorizationScopesThe authorization scopes supported by this route.
AuthorizationTypeThe authorization type for the route. For WebSocket APIs, valid values are NONE for open access, AWS_IAM for using AWS IAM permissions, and CUSTOM for using a Lambda authorizer For HTTP APIs, valid values are NONE for open access, JWT for using JSON Web Tokens, AWS_IAM for using AWS IAM permissions, and CUSTOM for using a Lambda authorizer.
AuthorizerIdThe identifier of the Authorizer resource to be associated with this route. The authorizer identifier is generated by API Gateway when you created the authorizer.
ModelSelectionExpressionThe model selection expression for the route. Supported only for WebSocket APIs.
OperationNameThe operation name for the route.
RequestModelsThe request models for the route. Supported only for WebSocket APIs.
RequestParametersThe request parameters for the route. Supported only for WebSocket APIs.
RouteKey[required] The route key for the route.
RouteResponseSelectionExpressionThe route response selection expression for the route. Supported only for WebSocket APIs.
TargetThe target for the route.
Value¶
A list with the following syntax:
list(
ApiGatewayManaged = TRUE|FALSE,
ApiKeyRequired = TRUE|FALSE,
AuthorizationScopes = list(
"string"
),
AuthorizationType = "NONE"|"AWS_IAM"|"CUSTOM"|"JWT",
AuthorizerId = "string",
ModelSelectionExpression = "string",
OperationName = "string",
RequestModels = list(
"string"
),
RequestParameters = list(
list(
Required = TRUE|FALSE
)
),
RouteId = "string",
RouteKey = "string",
RouteResponseSelectionExpression = "string",
Target = "string"
)
Request syntax¶
svc$create_route(
ApiId = "string",
ApiKeyRequired = TRUE|FALSE,
AuthorizationScopes = list(
"string"
),
AuthorizationType = "NONE"|"AWS_IAM"|"CUSTOM"|"JWT",
AuthorizerId = "string",
ModelSelectionExpression = "string",
OperationName = "string",
RequestModels = list(
"string"
),
RequestParameters = list(
list(
Required = TRUE|FALSE
)
),
RouteKey = "string",
RouteResponseSelectionExpression = "string",
Target = "string"
)