Resource: Definition
Represents a definition for example schema, request, response definitions contained in an API version. A definition is added/updated/deleted in an API version when a new spec is added or an existing spec is updated/deleted in a version. Currently, definition will be created only corresponding to OpenAPI spec as parsing is supported for OpenAPI spec. Also, within OpenAPI spec, only schema
object is supported.
JSON representation |
---|
{ "name": string, "spec": string, "type": enum ( |
Fields | |
---|---|
name |
Identifier. The name of the definition. Format: |
spec |
Output only. The name of the spec from where the definition was parsed. Format is |
type |
Output only. The type of the definition. |
createTime |
Output only. The time at which the definition was created. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: |
updateTime |
Output only. The time at which the definition was last updated. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: |
attributes |
Optional. The list of user defined attributes associated with the definition resource. The key is the attribute name. It will be of the format: An object containing a list of |
Union field
|
|
schema |
Output only. The value of a schema definition. |
Schema
The schema details derived from the spec. Currently, this entity is supported for OpenAPI spec only. For OpenAPI spec, this maps to the schema defined in the definitions
section for OpenAPI 2.0 version and in components.schemas
section for OpenAPI 3.0 and 3.1 version.
JSON representation |
---|
{ "displayName": string, "rawValue": string } |
Fields | |
---|---|
displayName |
Output only. The display name of the schema. This will map to the name of the schema in the spec. |
rawValue |
Output only. The raw value of the schema definition corresponding to the schema name in the spec. A base64-encoded string. |
Type
Enumeration of definition types.
Enums | |
---|---|
TYPE_UNSPECIFIED |
Definition type unspecified. |
SCHEMA |
Definition type schema. |
Methods |
|
---|---|
|
Get details about a definition in an API version. |