ResourceProps

class aws_cdk.aws_apigateway.ResourceProps(*, default_cors_preflight_options=None, default_integration=None, default_method_options=None, parent, path_part)

Bases: aws_cdk.aws_apigateway.ResourceOptions

__init__(*, default_cors_preflight_options=None, default_integration=None, default_method_options=None, parent, path_part)
Parameters
  • default_cors_preflight_options (Optional[CorsOptions]) – Adds a CORS preflight OPTIONS method to this resource and all child resources. You can add CORS at the resource-level using addCorsPreflight. Default: - CORS is disabled

  • default_integration (Optional[Integration]) – An integration to use as a default for all methods created within this API unless an integration is specified. Default: - Inherited from parent.

  • default_method_options (Optional[MethodOptions]) – Method options to use as a default for all methods created within this API unless custom options are specified. Default: - Inherited from parent.

  • parent (IResource) – The parent resource of this resource. You can either pass another Resource object or a RestApi object here.

  • path_part (str) – A path name for the resource.

Attributes

default_cors_preflight_options

Adds a CORS preflight OPTIONS method to this resource and all child resources.

You can add CORS at the resource-level using addCorsPreflight.

default :default: - CORS is disabled

Return type

Optional[CorsOptions]

default_integration

An integration to use as a default for all methods created within this API unless an integration is specified.

default :default: - Inherited from parent.

Return type

Optional[Integration]

default_method_options

Method options to use as a default for all methods created within this API unless custom options are specified.

default :default: - Inherited from parent.

Return type

Optional[MethodOptions]

parent

The parent resource of this resource.

You can either pass another Resource object or a RestApi object here.

Return type

IResource

path_part

A path name for the resource.

Return type

str