get_model¶
Operation¶
get_model
async
¶
get_model(input: GetModelInput, plugins: list[Plugin] | None = None) -> GetModelOutput
Describes an existing model defined for a RestApi resource.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
input
|
GetModelInput
|
An instance of |
required |
plugins
|
list[Plugin] | None
|
A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations. |
None
|
Returns:
| Type | Description |
|---|---|
GetModelOutput
|
An instance of |
Input¶
GetModelInput
dataclass
¶
Request to list information about a model in an existing RestApi resource.
Attributes¶
flatten
class-attribute
instance-attribute
¶
flatten: bool = False
A query parameter of a Boolean value to resolve (true) all external
model references and returns a flattened model schema or not (false)
The default is false.
Output¶
GetModelOutput
dataclass
¶
Represents the data structure of a method's request or response payload.
Attributes¶
content_type
class-attribute
instance-attribute
¶
content_type: str | None = None
The content-type for the model.
description
class-attribute
instance-attribute
¶
description: str | None = None
The description of the model.
id
class-attribute
instance-attribute
¶
id: str | None = None
The identifier for the model resource.
name
class-attribute
instance-attribute
¶
name: str | None = None
The name of the model. Must be an alphanumeric string.
response_metadata
class-attribute
instance-attribute
¶
response_metadata: ResponseMetadata = field(default=EMPTY_RESPONSE_METADATA, repr=False, compare=False)
Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.
schema
class-attribute
instance-attribute
¶
schema: str | None = None
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.