Example
Code Block | ||
---|---|---|
| ||
version: 1.0 api: name: petstore version: 2.1 displayName: Petstore # optional description: a simple petstore api # optional type: REST backend: url: https://internal.petstore.com gateway: protocol: https path: /petstore documentation: # optional url: https://somewhere.com/openapi |
...
Name | Type | Required | Description |
---|---|---|---|
version | String | yes | Version of Open Proxy Spec definition used by this file. Must be “1.0”. |
api | yes | basic information about this API | |
backend | yes | Info about the backend to which requests should be forwarded by the gatway | |
gateway | yes | Info on how and where the API is accessible in the gateway | |
documentation | no | Info on where to get documentation (OpenAPI file). Only required for external OpenAPI files, not if file is present in the same repository. |
...
Name | Type | Required | Description |
---|---|---|---|
url | String | yes | the url of the backend to which API requests will be forwarded. |
gateway
Name | Type | Required | Description |
---|
protocol | String | yes |
protocoll that has to be used when calling the API through the gateway. Must be “http” or “https”. | |||
path | String | yes | Context path at which the API is located in the gateway. Will be appended to gateway base url. Must start with a '/'. Not supported by all gateways. |
documentation
Name | Type | Required | Description |
---|---|---|---|
url | String | yes | External url of OpenAPI document for this API. |