CfnRestApiLogsMixin

class aws_cdk.mixins_preview.aws_apigateway.mixins.CfnRestApiLogsMixin(log_type, log_delivery)

Bases: Mixin

The AWS::ApiGateway::RestApi resource creates a REST API.

For more information, see restapi:create in the Amazon API Gateway REST API Reference . .. epigraph:

On January 1, 2016, the Swagger Specification was donated to the `OpenAPI initiative <https://docs.aws.amazon.com/https://www.openapis.org/>`_ , becoming the foundation of the OpenAPI Specification.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-restapi.html

CloudformationResource:

AWS::ApiGateway::RestApi

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import aws_logs as logs
from aws_cdk.mixins_preview.aws_apigateway import mixins as apigateway_mixins

# logs_delivery: logs.ILogsDelivery

cfn_rest_api_logs_mixin = apigateway_mixins.CfnRestApiLogsMixin("logType", logs_delivery)

Create a mixin to enable vended logs for AWS::ApiGateway::RestApi.

Parameters:
  • log_type (str) – Type of logs that are getting vended.

  • log_delivery (ILogsDelivery) – Object in charge of setting up the delivery source, delivery destination, and delivery connection.

Methods

apply_to(resource)

Apply vended logs configuration to the construct.

Parameters:

resource (IConstruct)

Return type:

None

supports(construct)

Check if this mixin supports the given construct (has vendedLogs property).

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

ACCESS_LOGS = <aws_cdk.mixins_preview.aws_apigateway.mixins.CfnRestApiAccessLogs object>
EXECUTION_LOGS = <aws_cdk.mixins_preview.aws_apigateway.mixins.CfnRestApiExecutionLogs object>

Static Methods

classmethod is_mixin(x)

Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.