Skip to content

Commit 260e45a

Browse files
authored
Merge pull request OAI#942 from OAI/server-fix
Server fix
2 parents 94b2a04 + 205fc56 commit 260e45a

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

versions/3.0.md

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ Field Name | Type | Description
181181
---|:---:|---
182182
<a name="oasVersion"></a>openapi | [OpenAPI Version String](#oasVersion) | **Required.** Specifies the OpenAPI Specification version being used. It can be used by tooling Specifications and clients to interpret the version. The structure SHALL be `major`.`minor`.`patch`, where `patch` versions MUST be compatible with the existing `major`.`minor` tooling. Typically patch versions will be introduced to address errors in the documentation, and tooling SHOULD typically be compatible with the corresponding `major`.`minor` (3.0.*). Patch versions will correspond to patches of this document.
183183
<a name="oasInfo"></a>info | [Info Object](#infoObject) | **Required.** Provides metadata about the API. The metadata can be used by the clients if needed.
184-
<a name="oasHosts"></a>servers | [[Server Object](#serverObject)] | An optional array of Server Objects which provide connectivity information to a target server.
184+
<a name="oasServers"></a>servers | [[Server Object](#serverObject)] | An optional array of Server Objects which provide connectivity information to a target server.
185185
<a name="oasPaths"></a>paths | [Paths Object](#pathsObject) | **Required.** The available paths and operations for the API.
186186
<a name="oasComponents"></a>components | [Components Object](#componentsObject) | An element to hold various schemas for the specification.
187187
<a name="oasSecurity"></a>security | [[Security Requirement Object](#securityRequirementObject)] | A declaration of which security mechanisms can be used across the API. The list of values includes alternative security requirement objects that can be used. Only one of the security requirement objects need to be satisfied to authorize a request. Individual operations can override this definition.
@@ -325,7 +325,14 @@ This object can be extended with [Specification Extensions](#specificationExtens
325325

326326
##### Server Object Example
327327

328-
The following shows how multiple hosts can be described in the Server Object array
328+
A single server would be described as:
329+
330+
```yaml
331+
url: https://development.gigantic-server.com/v1
332+
description: Development server
333+
```
334+
335+
The following shows how multiple servers can be described, for example, at the OpenAPI Object's `servers`(#oasServers):
329336

330337
```yaml
331338
servers:
@@ -337,7 +344,7 @@ servers:
337344
description: Production server
338345
```
339346

340-
The following shows how templates can be used for a server configuration
347+
The following shows how templates can be used for a server configuration:
341348

342349
```yaml
343350
servers:
@@ -647,7 +654,7 @@ Field Name | Type | Description
647654
<a name="pathItemHead"></a>head | [Operation Object](#operationObject) | A definition of a HEAD operation on this path.
648655
<a name="pathItemPatch"></a>patch | [Operation Object](#operationObject) | A definition of a PATCH operation on this path.
649656
<a name="pathItemTrace"></a>trace | [Operation Object](#operationObject) | A definition of a TRACE operation on this path.
650-
<a name="pathItemServer"></a>servers | [Server Object](#serverObject) | An alternative `server` array to service all operations in this path.
657+
<a name="pathItemServers"></a>servers | [Server Object](#serverObject) | An alternative `server` array to service all operations in this path.
651658
<a name="pathItemParameters"></a>parameters | [[Parameter Object](#parameterObject) <span>&#124;</span> [Reference Object](#referenceObject)] | A list of parameters that are applicable for all the operations described under this path. These parameters can be overridden at the operation level, but cannot be removed there. The list MUST NOT include duplicated parameters. A unique parameter is defined by a combination of a [name](#parameterName) and [___location](#parameterIn). The list can use the [Reference Object](#referenceObject) to link to parameters that are defined at the [OpenAPI Object's parameters](#oasParameters).
652659

653660

@@ -753,7 +760,7 @@ Field Name | Type | Description
753760
<a name="operationCallbacks"></a>callbacks | [Callbacks Object](#callbacksObject) | The list of possible callbacks as they are returned from executing this operation.
754761
<a name="operationDeprecated"></a>deprecated | `boolean` | Declares this operation to be deprecated. Consumers SHOULD refrain from usage of the declared operation. Default value is `false`.
755762
<a name="operationSecurity"></a>security | [[Security Requirement Object](#securityRequirementObject)] | A declaration of which security mechanisms can be used for this operation. The list of values includes alternative security requirement objects that can be used. Only one of the security requirement objects need to be satisfied to authorize a request. This definition overrides any declared top-level [`security`](#oasSecurity). To remove a top-level security declaration, an empty array can be used.
756-
<a name="operationItemServer"></a>servers | [Server Object](#serverObject) | An alternative `server` array to service this operation. If an alternative `server` object is specified at the Path Item Object or Root level, it will be overridden by this value.
763+
<a name="operationServers"></a>servers | [Server Object](#serverObject) | An alternative `server` array to service this operation. If an alternative `server` object is specified at the Path Item Object or Root level, it will be overridden by this value.
757764

758765
This object can be extended with [Specification Extensions](#specificationExtensions).
759766

0 commit comments

Comments
 (0)