view services/schema/src/main/resources/schema-swagger.yaml @ 292:1738c834713c

Add schema service to serve combined API swagger file This patch serves an uber-api Swagger file from URL https://127.0.0.1:30000/schema/fullapi-swagger.yaml (or ... .json) Rviewed-by: sgehwolf Review-thread: http://icedtea.classpath.org/pipermail/thermostat/2017-October/025369.html
author Simon Tooke <stooke@redhat.com>
date Tue, 24 Oct 2017 14:46:18 -0400
parents
children 5e79312c8075
line wrap: on
line source

swagger: '2.0'
info:
  version: 0.0.1
  title: Thermostat Web Gateway Schema Service
  license:
    name: GPL v2 with Classpath Exception
    url: 'http://www.gnu.org/licenses'
produces:
  - application/json
  - application/yaml
  - text/html; charset=utf-8
basePath: /schema
paths:
  /fullapi-swagger.yaml:
    get:
      description: Get YAML description of combined Swagger API for Thermostat
      responses:
        '200':
          description: OK
          schema:
            $ref: '#/definitions/swagger-response-yaml'
  /fullapi-swagger.json:
    get:
      description: Get JSON description of combined Swagger API for Thermostat
      parameters:
        - $ref: '#/parameters/pretty'
      responses:
        '200':
          description: OK
          schema:
            $ref: '#/definitions/swagger-response-json'
  /doc/schema-swagger.yaml:
    get:
      description: Get YAML description of Swagger API for schma service
      responses:
        '200':
          description: OK
          schema:
            $ref: '#/definitions/swagger-response'
definitions:
  swagger-response-json:
    type: object
  swagger-response-yaml:
    type: object
parameters:
  pretty:
    name: pretty
    in: query
    description: true if JSON output should be pretty-printed
    type: boolean
    required: false
    default: false