1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104
|
swagger: '2.0'
info:
title: Responses
version: 0.1.0
definitions:
Error:
type: object
description: |
Contains all the properties any error response from the API will contain.
Some properties are optional so might be empty most of the time
required:
- code
- message
properties:
code:
description: the error code, this is not necessarily the http status code
type: integer
format: int32
message:
description: a human readable version of the error
type: string
helpUrl:
description: an optional url for getting more help about this error
type: string
format: uri
myArray:
type: array
items:
$ref: '#/definitions/myItems'
myItems:
type: object
properties:
propItems1:
type: integer
propItems2:
$ref: 'remote/remote.yaml#/aRemotePlace'
otherPlace:
Error:
type: object
properties:
message:
type: string
parameters:
BadRequest:
name: badRequest
in: body
schema:
$ref: '#/definitions/Error'
GoodRequest:
name: goodRequest
in: body
schema:
$ref: '#/otherPlace/Error'
PlainRequest:
name: plainRequest
in: body
schema:
type: integer
StrangeRequest:
name: stangeRequest
in: body
schema:
$ref: 'responses.yaml#/otherPlace/Error'
RemoteRequest:
name: remoteRequest
in: body
schema:
$ref: './remote/remote.yaml#/moreRemoteThanYouCanThink'
responses:
BadRequest:
description: Bad request
schema:
$ref: '#/definitions/Error'
GoodRequest:
description: good request
schema:
$ref: '#/otherPlace/Error'
PlainRequest:
description: plain request
schema:
type: integer
StrangeRequest:
description: strange request
schema:
$ref: 'responses.yaml#/otherPlace/Error'
RemoteRequest:
description: remote request
schema:
$ref: './remote/remote.yaml#/moreRemoteThanYouCanThink'
paths:
/:
get:
summary: GET
operationId: getAll
responses:
200:
description: Ok
|