Skip to content

api-morph / ServerVariableObject

Interface: ServerVariableObject

Defined in: src/types/openapi.ts:216

An object representing a Server Variable for server URL template substitution.

See

https://spec.openapis.org/oas/v3.1.1#server-variable-object

Indexable

[key: `x-${string}`]: any

This object MAY be extended with Specification Extensions.

Properties

default

default: string

Defined in: src/types/openapi.ts:229

REQUIRED. The default value to use for substitution, which SHALL be sent if an alternate value is not supplied. If the enum is defined, the value MUST exist in the enum's values. Note that this behavior is different from the Schema Object's default keyword, which documents the receiver's behavior rather than inserting the value into the data.


description?

optional description: string

Defined in: src/types/openapi.ts:234

An optional description for the server variable. CommonMark syntax MAY be used for rich text representation.


enum?

optional enum: string[]

Defined in: src/types/openapi.ts:221

An enumeration of string values to be used if the substitution options are from a limited set. The array MUST NOT be empty.

基于 MIT 许可证发布