{
    "swagger": "2.0",
    "info": {
        "title": "Pet Testing",
        "version": "1.0.0"
    },
    "host": "localhost:8080",
    "basePath": "/v1",
    "schemes": [
        "http"
    ],
    "consumes": [
        "application/json"
    ],
    "produces": [
        "application/json"
    ],
    "paths": {
        "/Pets": {
            "get": {
                "description": "Returns list of all pets.\n",
                "responses": {
                    "200": {
                        "description": "Array of pets",
                        "schema": {
                            "type": "array",
                            "items": {
                                "$ref": "#/definitions/Pet"
                            }
                        }
                    },
                    "default": {
                        "description": "Unexpected error",
                        "schema": {
                            "$ref": "#/definitions/Error"
                        }
                    }
                }
            }
        }
    },
    "definitions": {
        "Pet": {
            "type": "object",
            "discriminator": "petType",
            "properties": {
                "name": {
                    "type": "string"
                },
                "petType": {
                    "type": "string"
                }
            },
            "required": [
                "name",
                "petType"
            ]
        },
        "Cat": {
            "description": "A representation of a cat",
            "allOf": [
                {
                    "$ref": "#/definitions/Pet"
                },
                {
                    "type": "object",
                    "properties": {
                        "huntingSkill": {
                            "type": "string",
                            "description": "The measured skill for hunting",
                            "default": "lazy",
                            "enum": [
                                "clueless",
                                "lazy",
                                "adventurous",
                                "aggressive"
                            ]
                        }
                    },
                    "required": [
                        "huntingSkill"
                    ]
                }
            ]
        },
        "Lion": {
            "description": "A particular type of a cat",
            "allOf": [
                {
                    "$ref": "#/definitions/Cat"
                }
            ]
        },
        "Error": {
            "type": "object",
            "properties": {
                "code": {
                    "type": "integer",
                    "format": "int32"
                },
                "message": {
                    "type": "string"
                },
                "fields": {
                    "type": "string"
                }
            }
        }
    }
}
