65 lines
1.8 KiB
JSON
65 lines
1.8 KiB
JSON
{
|
|
"swagger": "2.0",
|
|
"info": {
|
|
"description": "This is a sample server celler server.",
|
|
"title": "Swagger Example API",
|
|
"termsOfService": "http://swagger.io/terms/",
|
|
"contact": {
|
|
"name": "API Support",
|
|
"url": "http://www.swagger.io/support",
|
|
"email": "support@swagger.io"
|
|
},
|
|
"license": {
|
|
"name": "Apache 2.0",
|
|
"url": "http://www.apache.org/licenses/LICENSE-2.0.html"
|
|
},
|
|
"version": "1.0"
|
|
},
|
|
"host": "localhost:8080",
|
|
"basePath": "/",
|
|
"paths": {
|
|
"/": {
|
|
"get": {
|
|
"summary": "获取当前用户的请求",
|
|
"responses": {
|
|
"200": {
|
|
"description": "OK",
|
|
"schema": {
|
|
"type": "array",
|
|
"items": {
|
|
"$ref": "#/definitions/models.CurrentUserResponse"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"definitions": {
|
|
"models.CurrentUserResponse": {
|
|
"type": "object",
|
|
"properties": {
|
|
"ip": {
|
|
"type": "string"
|
|
},
|
|
"userEmail": {
|
|
"type": "string"
|
|
},
|
|
"userId": {
|
|
"type": "string"
|
|
},
|
|
"valid": {
|
|
"type": "boolean"
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"securityDefinitions": {
|
|
"ApiKeyAuth": {
|
|
"description": "Description for what is this security definition being used",
|
|
"type": "apiKey",
|
|
"name": "Authorization",
|
|
"in": "header"
|
|
}
|
|
}
|
|
} |