...

Text file src/github.com/go-openapi/validate/fixtures/bugs/123/swagger.yml

Documentation: github.com/go-openapi/validate/fixtures/bugs/123

     1---
     2swagger: '2.0'
     3info:
     4  version: 0.1.0
     5  title: 'AttendList'
     6  description: |
     7    AttendList service.
     8  contact:
     9    name: API Support
    10    url: http://attendlist.co/support
    11    email: contact@evecon.co
    12consumes:
    13  - application/json
    14produces:
    15  - application/json
    16definitions:
    17  Service:
    18    description: Service information
    19    type: object
    20    properties:
    21      Name:
    22        type: string
    23        readOnly: true
    24      Build:
    25        type: string
    26        readOnly: true
    27  Versions:
    28    description: Representation of Version information
    29    type: object
    30    properties:
    31      Id:
    32        type: integer
    33        format: int64
    34        readOnly: true
    35      Version:
    36        type: integer
    37        format: int64
    38        readOnly: true
    39      Created:
    40        type: integer
    41        format: int64
    42        readOnly: true
    43      Updated:
    44        type: integer
    45        format: int64
    46        readOnly: true
    47      Deleted:
    48        type: boolean
    49        readOnly: true
    50  Dates:
    51    description: Representation of Date interval
    52    type: object
    53    properties:
    54      StartDate:
    55        type: string
    56        format: date-time
    57      EndDate:
    58        type: string
    59        format: date-time
    60  Location:
    61    description: Representation of lat-lon Location
    62    type: object
    63    properties:
    64      Latitude:
    65        type: number
    66        format: float
    67      Longitude:
    68        type: number
    69        format: float
    70  Event:
    71    description: Representation of an Event
    72    allOf:
    73    - $ref: '#/definitions/Versions'
    74    - $ref: '#/definitions/Dates'
    75    - $ref: '#/definitions/Location'
    76    - type: object
    77      properties:
    78        Name:
    79          type: string
    80        URL:
    81          type: string
    82        Notes:
    83          type: string
    84        Autosearch:
    85          type: boolean
    86    example:
    87      StartDate: "2015-11-01T12:00:00Z"
    88      EndDate: "2015-11-05T12:00:00Z"
    89      Latitude: 59.842609
    90      Longitude: 30.319087
    91      Name: "Bikers meeting"
    92      URL: "http://attendlist.co"
    93      Notes: "Yet another bikers meeting"
    94      Autosearch: false
    95paths:
    96  /services:
    97    get:
    98      description: Get services information.
    99      tags:
   100      - services
   101      operationId: getServices
   102      responses:
   103        '200':
   104          description: Successful response
   105          schema:
   106            title: ArrayOfServices
   107            type: array
   108            items:
   109              $ref: '#/definitions/Service'
   110        default:
   111          description: Generic Error
   112  /events:
   113    get:
   114      description: Get events.
   115      tags:
   116      - events
   117      operationId: getEvents
   118      responses:
   119        '200':
   120          description: Successful response
   121          schema:
   122            title: ArrayOfEvents
   123            type: array
   124            items:
   125              $ref: '#/definitions/Event'
   126        default:
   127          description: Generic Error
   128    post:
   129      description: Create new event.
   130      tags:
   131      - events
   132      operationId: postEvent
   133      parameters:
   134        - name: Event
   135          in: body
   136          description: New events
   137          required: true
   138          schema:
   139            $ref: '#/definitions/Event'
   140      responses:
   141        '201':
   142          description: |
   143            Successful response.
   144          headers:
   145            'Location':
   146              description: Contains link to the new Event resource
   147              type: string
   148        default:
   149          description: Generic Error
   150  /events/{id}:
   151    parameters:
   152      - name: id
   153        in: path
   154        description: Existing event id.
   155        required: true
   156        type: integer
   157        format: int64
   158    get:
   159      description: Get event by id.
   160      tags:
   161      - events
   162      operationId: getEventById
   163      responses:
   164        '200':
   165          description: Successful response
   166          schema:
   167            title: Newly created event
   168            $ref: '#/definitions/Event'
   169        default:
   170          description: Generic Error
   171    put:
   172      description: Update existing event.
   173      tags:
   174      - events
   175      operationId: putEventById
   176      parameters:
   177        - name: Event
   178          in: body
   179          description: Existing event
   180          required: true
   181          schema:
   182            $ref: '#/definitions/Event'
   183      responses:
   184        '204':
   185          description: Successful response
   186        default:
   187          description: Generic Error
   188    delete:
   189      description: Delete event by id.
   190      tags:
   191      - events
   192      operationId: deleteEventById
   193      responses:
   194        '204':
   195          description: Successful response
   196        default:
   197          description: Generic Error

View as plain text