UNPKG

@microsoft.azure/autorest.testserver

Version:

This project contains a set of OpenAPI definitions and a server implementing the corresponding API. Use this to test compliance of AutoRest generators.

183 lines (182 loc) 6.01 kB
{ "swagger": "2.0", "info": { "title": "AutoRest Bool Test Service", "description": "Test Infrastructure for AutoRest", "version": "1.0.0" }, "host": "localhost:3000", "schemes": [ "http" ], "produces": [ "application/json"], "consumes": [ "application/json"], "paths": { "/bool/true": { "get": { "operationId": "bool_getTrue", "description": "Get true Boolean value", "tags": [ "Bool Operations" ], "responses": { "200": { "description": "The true Boolean value", "schema": { "type": "boolean", "enum": [true] } }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } }, "put": { "operationId": "bool_putTrue", "description": "Set Boolean value true", "parameters": [ { "name": "boolBody", "in": "body", "schema" : { "type": "boolean", "enum": [true] }, "required": true } ], "tags": [ "Bool Operations" ], "responses": { "200": { "description": "Empty Response" }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } } }, "/bool/false": { "get": { "operationId": "bool_getFalse", "description": "Get false Boolean value", "tags": [ "Bool Operations" ], "responses": { "200": { "description": "The false Boolean value", "schema": { "type": "boolean", "enum": [false] } }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } }, "put": { "operationId": "bool_putFalse", "description": "Set Boolean value false", "parameters": [ { "name": "boolBody", "in": "body", "schema" : { "type": "boolean", "enum": [false] }, "required": true } ], "tags": [ "Bool Operations" ], "responses": { "200": { "description": "Empty Response" }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } } }, "/bool/null": { "get": { "operationId": "bool_getNull", "description": "Get null Boolean value", "tags": [ "Bool Operations" ], "responses": { "200": { "description": "The null Boolean value", "schema": { "type": "boolean" } }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } } }, "/bool/invalid": { "get": { "operationId": "bool_getInvalid", "description": "Get invalid Boolean value", "tags": [ "Bool Operations" ], "responses": { "200": { "description": "The invalid Boolean value", "schema": { "type": "boolean" } }, "default": { "description": "Unexpected error", "schema": { "$ref": "#/definitions/Error" } } } } } }, "definitions": { "Error": { "type": "object", "properties": { "status": { "type": "integer", "format": "int32" }, "message": { "type": "string" } } } } }