Home > @codemonger-io/cdk-rest-api-with-spec > RestApiWithSpec > addModel
This API is provided as a beta preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.
Returns the addModel function augmented with the features to build the OpenAPI definition.
Signature:
addModel(id: string, props: ModelOptionsWithSpec): apigateway.Model;|
Parameter |
Type |
Description |
|---|---|---|
|
id |
string | |
|
props |
Returns:
apigateway.Model