CfnModelProps

class aws_cdk.aws_apigateway.CfnModelProps(*, rest_api_id, content_type=None, description=None, name=None, schema=None)

Bases: object

Properties for defining a CfnModel.

Parameters:
  • rest_api_id (str) – The string identifier of the associated RestApi.

  • content_type (Optional[str]) – The content-type for the model.

  • description (Optional[str]) – The description of the model.

  • name (Optional[str]) – A name for the model. If you don’t specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the model name. For more information, see Name Type . .. epigraph:: If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.

  • schema (Optional[Any]) – The schema for the model. For application/json models, this should be JSON schema draft 4 model. Do not include “* /” characters in the description of any properties because such “* /” characters may be interpreted as the closing marker for comments in some languages, such as Java or JavaScript, causing the installation of your API’s SDK generated by API Gateway to fail.

See:

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

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 import aws_apigateway as apigateway

# schema: Any

cfn_model_props = apigateway.CfnModelProps(
    rest_api_id="restApiId",

    # the properties below are optional
    content_type="contentType",
    description="description",
    name="name",
    schema=schema
)

Attributes

content_type

The content-type for the model.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-model.html#cfn-apigateway-model-contenttype

description

The description of the model.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-model.html#cfn-apigateway-model-description

name

A name for the model.

If you don’t specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the model name. For more information, see Name Type . .. epigraph:

If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-model.html#cfn-apigateway-model-name

rest_api_id

The string identifier of the associated RestApi.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-model.html#cfn-apigateway-model-restapiid

schema

The schema for the model.

For application/json models, this should be JSON schema draft 4 model. Do not include “* /” characters in the description of any properties because such “* /” characters may be interpreted as the closing marker for comments in some languages, such as Java or JavaScript, causing the installation of your API’s SDK generated by API Gateway to fail.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apigateway-model.html#cfn-apigateway-model-schema