Skip to content
webron edited this page Jan 22, 2014 · 1 revision

The API Declaration provides information about API exposed on a resource or an endpoint.

NB: All fields are case-sensitive.

Quick Fields Reference

Field Name | Description | Type | Mandatory ---|---|:---:|:---:|--- swaggerVersion | Specifies the Swagger Specification version being used. | String | ✓
apiVersion | Provides the version of the application API (not to be confused by the spec version). | basePath | The root URL serving the API. | String | ✓ resourcePath | The relative path to the resource, from the basePath, which this API Specification describes. | String | apis | A list of the APIs exposed on this resource. | [API Object] | ??? models | | | produces | A list of MIME types the APIs on this resource can produce. | [String] | ??? consumes | A list of MIME types the APIs on this resource can consume. | [String] | ???

Fields

swaggerVersion
  • Specifies the Swagger Specification version being used.
  • This field MUST be included. It can be used by the Swagger UI and other clients to interpret the API listing.
  • Value type is a String. The value MUST be an existing Swagger Spec version. Currently, "1.0", "1.1", "1.2" are valid values.
  • Example:
"swaggerVersion" : "1.2"
errorResponses
  • Description of the possible error responses that can be received from this operation.
  • Page
Clone this wiki locally