get_route_responses

ApiGatewayV2.Client.get_route_responses(**kwargs)

Gets the RouteResponses for a Route.

See also: AWS API Documentation

Request Syntax

response = client.get_route_responses(
    ApiId='string',
    MaxResults='string',
    NextToken='string',
    RouteId='string'
)
Parameters
  • ApiId (string) --

    [REQUIRED]

    The API identifier.

  • MaxResults (string) -- The maximum number of elements to be returned for this resource.
  • NextToken (string) -- The next page of elements from this collection. Not valid for the last element of the collection.
  • RouteId (string) --

    [REQUIRED]

    The route ID.

Return type

dict

Returns

Response Syntax

{
    'Items': [
        {
            'ModelSelectionExpression': 'string',
            'ResponseModels': {
                'string': 'string'
            },
            'ResponseParameters': {
                'string': {
                    'Required': True|False
                }
            },
            'RouteResponseId': 'string',
            'RouteResponseKey': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    Success

    • Items (list) --

      The elements from this collection.

      • (dict) --

        Represents a route response.

        • ModelSelectionExpression (string) --

          Represents the model selection expression of a route response. Supported only for WebSocket APIs.

        • ResponseModels (dict) --

          Represents the response models of a route response.

          • (string) --

            • (string) --

              A string with a length between [1-128].

        • ResponseParameters (dict) --

          Represents the response parameters of a route response.

          • (string) --

            • (dict) --

              Validation constraints imposed on parameters of a request (path, query string, headers).

              • Required (boolean) --

                Whether or not the parameter is required.

        • RouteResponseId (string) --

          Represents the identifier of a route response.

        • RouteResponseKey (string) --

          Represents the route response key of a route response.

    • NextToken (string) --

      The next page of elements from this collection. Not valid for the last element of the collection.

Exceptions

  • ApiGatewayV2.Client.exceptions.NotFoundException
  • ApiGatewayV2.Client.exceptions.TooManyRequestsException
  • ApiGatewayV2.Client.exceptions.BadRequestException