|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299 |
- {
- "apiVersion": "1.0.0",
- "swaggerVersion": "1.2",
- "basePath": "http://petstore.swagger.io/api",
- "resourcePath": "/user",
- "produces": [
- "application/json"
- ],
- "apis": [
- {
- "path": "/user",
- "operations": [
- {
- "method": "POST",
- "summary": "Create user",
- "notes": "This can only be done by the logged in user.",
- "type": "void",
- "nickname": "createUser",
- "authorizations": {
- "oauth2": [
- {
- "scope": "test:anything",
- "description": "anything"
- }
- ]
- },
- "parameters": [
- {
- "name": "body",
- "description": "Created user object",
- "required": true,
- "type": "User",
- "paramType": "body"
- }
- ]
- }
- ]
- },
- {
- "path": "/user/logout",
- "operations": [
- {
- "method": "GET",
- "summary": "Logs out current logged in user session",
- "notes": "",
- "type": "void",
- "nickname": "logoutUser",
- "authorizations": {},
- "parameters": []
- }
- ]
- },
- {
- "path": "/user/createWithArray",
- "operations": [
- {
- "method": "POST",
- "summary": "Creates list of users with given input array",
- "notes": "",
- "type": "void",
- "nickname": "createUsersWithArrayInput",
- "authorizations": {
- "oauth2": [
- {
- "scope": "test:anything",
- "description": "anything"
- }
- ]
- },
- "parameters": [
- {
- "name": "body",
- "description": "List of user object",
- "required": true,
- "type": "array",
- "items": {
- "$ref": "User"
- },
- "paramType": "body"
- }
- ]
- }
- ]
- },
- {
- "path": "/user/createWithList",
- "operations": [
- {
- "method": "POST",
- "summary": "Creates list of users with given list input",
- "notes": "",
- "type": "void",
- "nickname": "createUsersWithListInput",
- "authorizations": {
- "oauth2": [
- {
- "scope": "test:anything",
- "description": "anything"
- }
- ]
- },
- "parameters": [
- {
- "name": "body",
- "description": "List of user object",
- "required": true,
- "type": "array",
- "items": {
- "$ref": "User"
- },
- "paramType": "body"
- }
- ]
- }
- ]
- },
- {
- "path": "/user/{username}",
- "operations": [
- {
- "method": "PUT",
- "summary": "Updated user",
- "notes": "This can only be done by the logged in user.",
- "type": "void",
- "nickname": "updateUser",
- "authorizations": {
- "oauth2": [
- {
- "scope": "test:anything",
- "description": "anything"
- }
- ]
- },
- "parameters": [
- {
- "name": "username",
- "description": "name that need to be deleted",
- "required": true,
- "type": "string",
- "paramType": "path"
- },
- {
- "name": "body",
- "description": "Updated user object",
- "required": true,
- "type": "User",
- "paramType": "body"
- }
- ],
- "responseMessages": [
- {
- "code": 400,
- "message": "Invalid username supplied"
- },
- {
- "code": 404,
- "message": "User not found"
- }
- ]
- },
- {
- "method": "DELETE",
- "summary": "Delete user",
- "notes": "This can only be done by the logged in user.",
- "type": "void",
- "nickname": "deleteUser",
- "authorizations": {
- "oauth2": [
- {
- "scope": "test:anything",
- "description": "anything"
- }
- ]
- },
- "parameters": [
- {
- "name": "username",
- "description": "The name that needs to be deleted",
- "required": true,
- "type": "string",
- "paramType": "path"
- }
- ],
- "responseMessages": [
- {
- "code": 400,
- "message": "Invalid username supplied"
- },
- {
- "code": 404,
- "message": "User not found"
- }
- ]
- },
- {
- "method": "GET",
- "summary": "Get user by user name",
- "notes": "",
- "type": "User",
- "nickname": "getUserByName",
- "authorizations": {},
- "parameters": [
- {
- "name": "username",
- "description": "The name that needs to be fetched. Use user1 for testing.",
- "required": true,
- "type": "string",
- "paramType": "path"
- }
- ],
- "responseMessages": [
- {
- "code": 400,
- "message": "Invalid username supplied"
- },
- {
- "code": 404,
- "message": "User not found"
- }
- ]
- }
- ]
- },
- {
- "path": "/user/login",
- "operations": [
- {
- "method": "GET",
- "summary": "Logs user into the system",
- "notes": "",
- "type": "string",
- "nickname": "loginUser",
- "authorizations": {},
- "parameters": [
- {
- "name": "username",
- "description": "The user name for login",
- "required": true,
- "type": "string",
- "paramType": "query"
- },
- {
- "name": "password",
- "description": "The password for login in clear text",
- "required": true,
- "type": "string",
- "paramType": "query"
- }
- ],
- "responseMessages": [
- {
- "code": 400,
- "message": "Invalid username and password combination"
- }
- ]
- }
- ]
- }
- ],
- "models": {
- "User": {
- "id": "User",
- "properties": {
- "id": {
- "type": "integer",
- "format": "int64"
- },
- "firstName": {
- "type": "string"
- },
- "username": {
- "type": "string"
- },
- "lastName": {
- "type": "string"
- },
- "email": {
- "type": "string"
- },
- "password": {
- "type": "string"
- },
- "phone": {
- "type": "string"
- },
- "userStatus": {
- "type": "integer",
- "format": "int32",
- "description": "User Status",
- "enum": [
- "1-registered",
- "2-active",
- "3-closed"
- ]
- }
- }
- }
- }
- }
|