...

Text file src/github.com/go-openapi/validate/fixtures/validation/example/valid-example-header-response.json

Documentation: github.com/go-openapi/validate/fixtures/validation/example

     1{
     2    "swagger": "2.0",
     3    "info": {
     4        "description": "This is a sample server Petstore server.\n\n[Learn about Swagger](http://swagger.wordnik.com) or join the IRC channel `#swagger` on irc.freenode.net.\n\nFor this sample, you can use the api key `special-key` to test the authorization filters\n",
     5        "version": "1.0.0",
     6        "title": "Swagger Petstore",
     7        "termsOfService": "http://helloreverb.com/terms/",
     8        "contact": {
     9            "name": "apiteam@wordnik.com"
    10        },
    11        "license": {
    12            "name": "Apache 2.0",
    13            "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
    14        }
    15    },
    16    "host": "petstore.swagger.wordnik.com",
    17    "basePath": "/v2",
    18    "schemes": [
    19        "http"
    20    ],
    21    "paths": {
    22        "/pets": {
    23          "get": {
    24            "tags": ["pet"],
    25            "summary": "list the pets",
    26            "operationId": "getPets",
    27            "responses": {
    28              "default": {
    29                "headers": {
    30                  "X-Rate-Limit": {
    31                    "type": "integer",
    32                    "format": "int32",
    33                    "example": 20
    34                  }
    35                },
    36                "description": "Generic Error"
    37              },
    38              "200": {
    39                "description": "Pets list",
    40                "schema": {
    41                  "type": "integer",
    42                  "format": "uint32",
    43                  "example": 10
    44                }
    45              }
    46            }
    47          }
    48        }
    49    },
    50    "definitions": {
    51        "Parent": {
    52          "$ref": "#/definitions/Category"
    53        },
    54        "Category": {
    55            "properties": {
    56                "id": {
    57                    "type": "integer",
    58                    "format": "int64"
    59                },
    60                "name": {
    61                    "type": "string"
    62                }
    63            }
    64        },
    65        "Pet": {
    66            "required": [
    67                "name",
    68                "photoUrls"
    69            ],
    70            "properties": {
    71                "id": {
    72                    "type": "integer",
    73                    "format": "int64"
    74                },
    75                "category": {
    76                    "$ref": "#/definitions/Category"
    77                },
    78                "name": {
    79                    "type": "string",
    80                    "example": "doggie"
    81                },
    82                "photoUrls": {
    83                    "type": "array",
    84                    "items": {
    85                        "type": "string"
    86                    }
    87                },
    88                "tags": {
    89                    "type": "array",
    90                    "items": {
    91                        "$ref": "#/definitions/Tag"
    92                    }
    93                },
    94                "status": {
    95                    "type": "string",
    96                    "description": "pet status in the store"
    97                }
    98            }
    99        },
   100        "Tag": {
   101            "properties": {
   102                "id": {
   103                    "type": "integer",
   104                    "format": "int64"
   105                },
   106                "name": {
   107                    "type": "string"
   108                }
   109            }
   110        }
   111    }
   112}
   113

View as plain text