title: How to return an array of objects in SwaggerHub?
body: <p>I am defining an API specification in SwaggerHub using OpenAPI 2.0. The <code>/contacts</code> request returns an array of contacts. The definition is below:</p>
  <pre class="lang-yaml prettyprint-override"><code>  /contacts:     
      get:
        tags:
        - contacts
        summary: Get all the contacts
        description: This displays all the contacts present for the user.
        operationId: getContact
        produces:
        - application/json
        - application/xml  
        responses:
         200:
          description: successful operation
          schema:
            $ref: '#/definitions/AllContacts'
         400:
          description: Invalid id supplied
         404:
          description: Contact not found
         500:
          description: Server error
      definitions:
        AllContacts:
         type: array
         items:
         -  $ref: '#/definitions/ContactModel1'
         -  $ref: '#/definitions/ContactModel2'
      
          
        ContactModel1:
          type: object
          properties:
            id:
              type: integer
              example: 1
            firstName:
              type: string
              example: 'someValue'
            lastName:
              type: string
              example: 'someValue'
              
         ContactModel2:
          type: object
          properties:
            id:
              type: integer
              example: 2
            firstName:
              type: string
              example: 'someValue1'
            lastName:
              type: string
              example: 'someValue1'
  </code></pre>
  <p>For some reason, it only returns the second object not the whole array of objects.</p>
  <p>I am using OpenAPI 2.0 and suspect that the arrays are not well supported in this version.</p>