-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a3a6fac
commit a4436dc
Showing
3 changed files
with
166 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
{ | ||
"swagger": "2.0", | ||
"info": { | ||
"description": "This is a sample server Profile server. You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/). For this sample, you can use the api key `special-key` to test the authorization filters.", | ||
"version": "0.01", | ||
"title": "Swagger Users", | ||
"termsOfService": "http://swagger.io/terms/", | ||
"contact": { | ||
"email": "[email protected]" | ||
}, | ||
"license": { | ||
"name": "Apache 2.0", | ||
"url": "http://www.apache.org/licenses/LICENSE-2.0.html" | ||
} | ||
}, | ||
"host": "localhost:3000", | ||
"basePath": "/api", | ||
"tags": [ | ||
{ | ||
"name": "pet", | ||
"description": "Everything about your Pets", | ||
"externalDocs": { | ||
"description": "Find out more", | ||
"url": "http://swagger.io" | ||
} | ||
}, | ||
{ | ||
"name": "store", | ||
"description": "Access to Petstore orders" | ||
}, | ||
{ | ||
"name": "user", | ||
"description": "Operations about user", | ||
"externalDocs": { | ||
"description": "Find out more about our store", | ||
"url": "http://swagger.io" | ||
} | ||
} | ||
], | ||
"schemes": ["https", "http"], | ||
"paths": { | ||
"/users": { | ||
"get": { | ||
"tags": ["user"], | ||
"summary": "Get users", | ||
"operationId": "findgetUsers", | ||
"produces": ["application/json", "application/xml"], | ||
"parameters": [], | ||
"responses": { | ||
"200": { | ||
"description": "successful operation", | ||
"schema": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/User" | ||
} | ||
} | ||
}, | ||
"400": { | ||
"description": "Invalid status value" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"securityDefinitions": { | ||
"api_key": { | ||
"type": "apiKey", | ||
"name": "api_key", | ||
"in": "header" | ||
}, | ||
"petstore_auth": { | ||
"type": "oauth2", | ||
"authorizationUrl": "https://petstore.swagger.io/oauth/authorize", | ||
"flow": "implicit", | ||
"scopes": { | ||
"read:pets": "read your pets", | ||
"write:pets": "modify pets in your account" | ||
} | ||
} | ||
}, | ||
"definitions": { | ||
"ApiResponse": { | ||
"type": "object", | ||
"properties": { | ||
"code": { | ||
"type": "integer", | ||
"format": "int32" | ||
}, | ||
"type": { | ||
"type": "string" | ||
}, | ||
"message": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"User": { | ||
"type": "object", | ||
"properties": { | ||
"id": { | ||
"type": "integer", | ||
"format": "int64" | ||
}, | ||
"name": { | ||
"type": "string" | ||
}, | ||
"avatar": { | ||
"type": "string" | ||
}, | ||
"email": { | ||
"type": "string" | ||
}, | ||
"title": { | ||
"type": "string" | ||
}, | ||
"department": { | ||
"type": "string" | ||
}, | ||
"role": { | ||
"type": "string" | ||
}, | ||
"status": { | ||
"type": "string" | ||
} | ||
}, | ||
"xml": { | ||
"name": "User" | ||
} | ||
} | ||
}, | ||
"externalDocs": { | ||
"description": "Find out more about Swagger", | ||
"url": "http://swagger.io" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
/* eslint-disable */ | ||
/* tslint:disable */ | ||
/* | ||
* --------------------------------------------------------------- | ||
* ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API ## | ||
* ## ## | ||
* ## AUTHOR: acacode ## | ||
* ## SOURCE: https://github.com/acacode/swagger-typescript-api ## | ||
* --------------------------------------------------------------- | ||
*/ | ||
|
||
export interface ApiResponse { | ||
/** @format int32 */ | ||
code?: number | ||
type?: string | ||
message?: string | ||
} | ||
|
||
export interface User { | ||
/** @format int64 */ | ||
id?: number | ||
name?: string | ||
avatar?: string | ||
email?: string | ||
title?: string | ||
department?: string | ||
role?: string | ||
status?: string | ||
} |