Skip to content

Cors

Source code in docs_src/capo_apigatewayv2/types/cors.py
class Cors(TypedDict, closed=True):
    allow_credentials: NotRequired["capo_apigatewayv2.types.__boolean.__boolean"]
    """<p>Specifies whether credentials are included in the CORS request. Supported only for HTTP APIs.</p>"""
    allow_headers: NotRequired[
        "capo_apigatewayv2.types.cors_header_list.CorsHeaderList"
    ]
    """<p>Represents a collection of allowed headers. Supported only for HTTP APIs.</p>"""
    allow_methods: NotRequired[
        "capo_apigatewayv2.types.cors_method_list.CorsMethodList"
    ]
    """<p>Represents a collection of allowed HTTP methods. Supported only for HTTP APIs.</p>"""
    allow_origins: NotRequired[
        "capo_apigatewayv2.types.cors_origin_list.CorsOriginList"
    ]
    """<p>Represents a collection of allowed origins. Supported only for HTTP APIs.</p>"""
    expose_headers: NotRequired[
        "capo_apigatewayv2.types.cors_header_list.CorsHeaderList"
    ]
    """<p>Represents a collection of exposed headers. Supported only for HTTP APIs.</p>"""
    max_age: NotRequired[
        "capo_apigatewayv2.types.integer_with_length_between_minus1_and86400.IntegerWithLengthBetweenMinus1And86400"
    ]
    """<p>The number of seconds that the browser should cache preflight request results. Supported only for HTTP APIs.</p>"""

allow_credentials instance-attribute

allow_credentials: NotRequired[__boolean]

Specifies whether credentials are included in the CORS request. Supported only for HTTP APIs.

allow_headers instance-attribute

allow_headers: NotRequired[CorsHeaderList]

Represents a collection of allowed headers. Supported only for HTTP APIs.

allow_methods instance-attribute

allow_methods: NotRequired[CorsMethodList]

Represents a collection of allowed HTTP methods. Supported only for HTTP APIs.

allow_origins instance-attribute

allow_origins: NotRequired[CorsOriginList]

Represents a collection of allowed origins. Supported only for HTTP APIs.

expose_headers instance-attribute

expose_headers: NotRequired[CorsHeaderList]

Represents a collection of exposed headers. Supported only for HTTP APIs.

max_age instance-attribute

The number of seconds that the browser should cache preflight request results. Supported only for HTTP APIs.