Created
January 27, 2021 02:24
-
-
Save leric/4da4b8568c24ceba0960519e2a574e0b to your computer and use it in GitHub Desktop.
apihub api spec
This file contains hidden or 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
openapi: 3.0.2 | |
info: | |
title: FastAPI | |
version: 0.1.0 | |
paths: | |
/oauth2/token: | |
post: | |
tags: | |
- OAuth2 | |
summary: Login For Access Token | |
description: |- | |
OAuth2 password认证,获取access-token | |
:return: | |
operationId: login_for_access_token_oauth2_token_post | |
requestBody: | |
content: | |
application/x-www-form-urlencoded: | |
schema: | |
$ref: '#/components/schemas/Body_login_for_access_token_oauth2_token_post' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/AccessToken' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
/oauth2/users/me: | |
get: | |
tags: | |
- OAuth2 | |
summary: Read Users Me | |
description: |- | |
当前登陆用户个人信息 | |
:return: | |
operationId: read_users_me_oauth2_users_me_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/UserToken' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/qps: | |
get: | |
tags: | |
- Monitor | |
summary: Service Qps | |
description: |- | |
服务QPS曲线series | |
:return: | |
operationId: service_qps_api_monitor_service_qps_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: array | |
items: | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Service Qps Api Monitor Service Qps Get | |
type: array | |
items: | |
$ref: '#/components/schemas/StatsSeries' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/apdex: | |
get: | |
tags: | |
- Monitor | |
summary: Service Apdex | |
description: |- | |
服务性能指标曲线series | |
:return: | |
operationId: service_apdex_api_monitor_service_apdex_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: array | |
items: | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/status_code: | |
get: | |
tags: | |
- Monitor | |
summary: Service Status Code Dist | |
description: |- | |
服务返回HTTP状态码分布 | |
:return: | |
operationId: service_status_code_dist_api_monitor_service_status_code_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: array | |
items: | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/client_app/dist: | |
get: | |
tags: | |
- Monitor | |
summary: Service Clients App Dist | |
description: |- | |
服务各客户端请求量分布 | |
:return: | |
operationId: service_clients_app_dist_api_monitor_service_client_app_dist_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: array | |
items: | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/client_app/qps: | |
get: | |
tags: | |
- Monitor | |
summary: Service Client App Qps | |
description: |- | |
服务各客户端请求量堆叠曲线 | |
:return: | |
operationId: service_client_app_qps_api_monitor_service_client_app_qps_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: array | |
items: | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/upstream/qps: | |
get: | |
tags: | |
- Monitor | |
summary: Upstream Qps | |
description: |- | |
服务上游QPS堆叠曲线 | |
:return: | |
operationId: upstream_qps_api_monitor_service_upstream_qps_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/upstream/apdex: | |
get: | |
tags: | |
- Monitor | |
summary: Upstream Apdex | |
description: |- | |
服务上游性能曲线 | |
:return: | |
operationId: upstream_apdex_api_monitor_service_upstream_apdex_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/service/method_path/dist: | |
get: | |
tags: | |
- Monitor | |
summary: Service Path Dist | |
description: |- | |
服务路径/方法请求量分布 | |
:return: | |
operationId: service_path_dist_api_monitor_service_method_path_dist_get | |
parameters: | |
- required: true | |
schema: | |
title: Service names | |
type: string | |
name: s | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/apps/qps: | |
get: | |
tags: | |
- Monitor | |
summary: App Service Qps | |
description: |- | |
客户端使用的各服务QPS堆叠曲线series | |
:return: | |
operationId: app_service_qps_api_monitor_apps_qps_get | |
parameters: | |
- required: true | |
schema: | |
title: Client app names | |
type: array | |
items: | |
type: string | |
name: app | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/apps/status_code: | |
get: | |
tags: | |
- Monitor | |
summary: App Status Code Dist | |
description: |- | |
客户端请求服务返回HTP状态吗分布 | |
:return: | |
operationId: app_status_code_dist_api_monitor_apps_status_code_get | |
parameters: | |
- required: true | |
schema: | |
title: Client app names | |
type: array | |
items: | |
type: string | |
name: app | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/gateway/qps: | |
get: | |
tags: | |
- Monitor | |
summary: Gateway Qps | |
description: |- | |
网关QPS曲线series | |
:return: | |
operationId: gateway_qps_api_monitor_gateway_qps_get | |
parameters: | |
- required: true | |
schema: | |
title: Env names | |
type: array | |
items: | |
type: string | |
name: env | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/gateway/concurrency: | |
get: | |
tags: | |
- Monitor | |
summary: Gateway Concurrency | |
description: |- | |
网关并发连接数曲线 | |
:return: | |
operationId: gateway_concurrency_api_monitor_gateway_concurrency_get | |
parameters: | |
- required: true | |
schema: | |
title: Env names | |
type: array | |
items: | |
type: string | |
name: env | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/gateway/cpu: | |
get: | |
tags: | |
- Monitor | |
summary: Gateway Cpu | |
description: |- | |
网关服务器CPU使用曲线 | |
:return: | |
operationId: gateway_cpu_api_monitor_gateway_cpu_get | |
parameters: | |
- required: true | |
schema: | |
title: Env names | |
type: array | |
items: | |
type: string | |
name: env | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/gateway/mem: | |
get: | |
tags: | |
- Monitor | |
summary: Gateway Memory | |
description: |- | |
网关服务器内存使用曲线 | |
:return: | |
operationId: gateway_memory_api_monitor_gateway_mem_get | |
parameters: | |
- required: true | |
schema: | |
title: Env names | |
type: array | |
items: | |
type: string | |
name: env | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/monitor/gateway/network: | |
get: | |
tags: | |
- Monitor | |
summary: Gateway Network Io | |
description: |- | |
网关服务器网络IO曲线 | |
:return: | |
operationId: gateway_network_io_api_monitor_gateway_network_get | |
parameters: | |
- required: true | |
schema: | |
title: Env names | |
type: array | |
items: | |
type: string | |
name: env | |
in: query | |
- required: true | |
schema: | |
title: Since how long ago | |
type: string | |
name: since | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/service/new: | |
post: | |
tags: | |
- Service | |
summary: Create Service | |
description: |- | |
创建新服务 | |
:return: | |
operationId: create_service_api_service_new_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateServiceRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}': | |
get: | |
tags: | |
- Service | |
summary: Get Service Info | |
description: |- | |
获取服务基本信息 | |
:return: | |
operationId: get_service_info_api_service__ns___name__get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PublicServiceInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
delete: | |
tags: | |
- Service | |
summary: Delete Service | |
description: |- | |
删除服务 | |
:return: | |
operationId: delete_service_api_service__ns___name__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/upstream': | |
get: | |
tags: | |
- Service | |
summary: Get Service Upstreams | |
description: |- | |
获取服务详细信息 | |
:return: | |
operationId: get_service_upstreams_api_service__ns___name__upstream_get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get Service Upstreams Api Service Ns Name Upstream Get | |
type: array | |
items: | |
$ref: '#/components/schemas/ServiceUpstream' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/service/{ns}/{name}/policy': | |
get: | |
tags: | |
- Service | |
summary: Get Service Policy | |
description: |- | |
获取服务策略配置列表 | |
:return: | |
operationId: get_service_policy_api_service__ns___name__policy_get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get Service Policy Api Service Ns Name Policy Get | |
type: array | |
items: | |
$ref: '#/components/schemas/Policy' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/service/{ns}/{name}/sla': | |
get: | |
tags: | |
- Service | |
summary: Get Service Sla | |
description: |- | |
获取服务SLA列表 | |
:return: | |
operationId: get_service_sla_api_service__ns___name__sla_get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get Service Sla Api Service Ns Name Sla Get | |
type: array | |
items: | |
$ref: '#/components/schemas/ServiceSLA' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/service/{ns}/{name}/client': | |
get: | |
tags: | |
- Service | |
summary: Get Service Clients | |
description: |- | |
获取服务客户端列表 | |
:return: | |
operationId: get_service_clients_api_service__ns___name__client_get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: false | |
schema: | |
title: Match keyword in client name and description | |
type: string | |
default: '' | |
name: kw | |
in: query | |
- required: false | |
schema: | |
title: Sort result | |
type: string | |
default: create_at | |
name: order | |
in: query | |
- required: false | |
schema: | |
title: Items per page | |
type: integer | |
default: 10 | |
name: limit | |
in: query | |
- required: false | |
schema: | |
title: Pagination offset | |
type: integer | |
default: 0 | |
name: offset | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PagedResult_ServiceClientAuth_' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/service/{ns}/{name}/basic': | |
post: | |
tags: | |
- Service | |
summary: Update Service Basic | |
description: |- | |
设置服务基本配置 | |
:return: | |
operationId: update_service_basic_api_service__ns___name__basic_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceBasicInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/service/{ns}/{name}/upstream/{usid}': | |
post: | |
tags: | |
- Service | |
summary: Save Service Upstream | |
description: |- | |
设置服务上游配置 | |
:return: | |
operationId: save_service_upstream_api_service__ns___name__upstream__usid__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Upstream id | |
type: integer | |
name: usid | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateUpstreamRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceUpstream' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Service | |
summary: Delete Service Upstream | |
description: |- | |
删除服务上游配置 | |
:return: | |
operationId: delete_service_upstream_api_service__ns___name__upstream__usid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Upstream id | |
type: integer | |
name: usid | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/upstream/{usid}/status': | |
post: | |
tags: | |
- Service | |
summary: Toggle Service Upstream | |
description: |- | |
设置服务上游状态:on,off,canary | |
:return: | |
operationId: toggle_service_upstream_api_service__ns___name__upstream__usid__status_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Upstream ID | |
type: integer | |
name: usid | |
in: path | |
- required: true | |
schema: | |
title: Set service upstream status | |
type: string | |
name: status | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/policy/{pid}': | |
post: | |
tags: | |
- Service | |
summary: Save Service Policy | |
description: |- | |
保存服务策略配置 | |
:return: | |
operationId: save_service_policy_api_service__ns___name__policy__pid__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Path policy id | |
type: integer | |
name: pid | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreatePolicyRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/Policy' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Service | |
summary: Delete Service Policy | |
description: |- | |
删除服务策略配置 | |
:return: | |
operationId: delete_service_policy_api_service__ns___name__policy__pid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Path policy id | |
type: integer | |
name: pid | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/sla/{slaid}': | |
post: | |
tags: | |
- Service | |
summary: Save Service Level | |
description: |- | |
保存服务SLA配置 | |
:return: | |
operationId: save_service_level_api_service__ns___name__sla__slaid__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: SLA id | |
type: integer | |
name: slaid | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateServiceLevelRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceSLA' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Service | |
summary: Delete Service Level | |
description: |- | |
删除服务SLA配置 | |
:return: | |
operationId: delete_service_level_api_service__ns___name__sla__slaid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: SLA id | |
type: integer | |
name: slaid | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/sla/{slaid}/policy/{pid}': | |
post: | |
tags: | |
- Service | |
summary: Save Sla Policy | |
description: |- | |
保存服务SLA策略配置 | |
:return: | |
operationId: save_sla_policy_api_service__ns___name__sla__slaid__policy__pid__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: SLA id | |
type: integer | |
name: slaid | |
in: path | |
- required: true | |
schema: | |
title: SLA policy id | |
type: integer | |
name: pid | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreatePolicyRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/Policy' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Service | |
summary: Delete Sla Policy | |
description: |- | |
删除服务SLA策略配置 | |
:return: | |
operationId: delete_sla_policy_api_service__ns___name__sla__slaid__policy__pid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: SLA id | |
type: integer | |
name: slaid | |
in: path | |
- required: true | |
schema: | |
title: SLA policy id | |
type: integer | |
name: pid | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/client/{caid}': | |
post: | |
tags: | |
- Service | |
summary: Handle Client Application | |
description: |- | |
处理应用的服务申请 approve,deny,revoke | |
:return: | |
operationId: handle_client_application_api_service__ns___name__client__caid__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Client Application ID | |
type: integer | |
name: caid | |
in: path | |
- required: true | |
schema: | |
title: approve|deny | |
type: string | |
name: action | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/application': | |
post: | |
tags: | |
- Service | |
summary: Apply Service | |
description: |- | |
应用提交服务申请 | |
:return: | |
operationId: apply_service_api_service__ns___name__application_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceApplyRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/service/{ns}/{name}/client/{caid}/sla': | |
post: | |
tags: | |
- Service | |
summary: Set Service Client Sla | |
description: |- | |
设置应用的服务等级 | |
:return: | |
operationId: set_service_client_sla_api_service__ns___name__client__caid__sla_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Service name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: Client Auth ID | |
type: integer | |
name: caid | |
in: path | |
- required: true | |
schema: | |
title: SLA id | |
type: integer | |
name: sla_id | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/app/new: | |
post: | |
tags: | |
- App | |
summary: Create App | |
description: |- | |
创建应用 | |
:return: | |
operationId: create_app_api_app_new_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateAppRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceClient' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/app/{ns}/{name}': | |
get: | |
tags: | |
- App | |
summary: Get App Info | |
description: |- | |
获取应用信息 | |
:return: | |
operationId: get_app_info_api_app__ns___name__get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: App name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PublicAppInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
post: | |
tags: | |
- App | |
summary: Edit App Info | |
description: |- | |
编辑应用 | |
:return: | |
operationId: edit_app_info_api_app__ns___name__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: App name | |
type: string | |
name: name | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/SaveAppInfo' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- App | |
summary: Delete App | |
description: |- | |
删除应用 | |
:return: | |
operationId: delete_app_api_app__ns___name__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: App name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/app/{ns}/{name}/key_gen': | |
post: | |
tags: | |
- App | |
summary: Gen App Secret | |
description: |- | |
重新生成secret_key,app的secret-key只有创建时会显示,之后不能查看只能生成新的 | |
:return: | |
operationId: gen_app_secret_api_app__ns___name__key_gen_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: App name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ServiceClientKey' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/gateway/new: | |
post: | |
tags: | |
- Gateway | |
summary: Create Env | |
description: |- | |
创建环境 | |
:return: | |
operationId: create_env_api_gateway_new_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateEnvRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/EnvInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/gateway/{ns}/{env}': | |
get: | |
tags: | |
- Gateway | |
summary: Get Env Info | |
description: |- | |
删除环境 | |
:return: | |
operationId: get_env_info_api_gateway__ns___env__get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/EnvInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
post: | |
tags: | |
- Gateway | |
summary: Edit Env | |
description: |- | |
编辑环境配置信息 | |
:return: | |
operationId: edit_env_api_gateway__ns___env__post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/SaveEnvInfo' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Gateway | |
summary: Delete Env | |
description: |- | |
删除环境 | |
:return: | |
operationId: delete_env_api_gateway__ns___env__delete | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/gateway/{ns}/{env}/services': | |
get: | |
tags: | |
- Gateway | |
summary: List Env Services | |
description: |- | |
列出环境下部署的服务 | |
:return: | |
operationId: list_env_services_api_gateway__ns___env__services_get | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response List Env Services Api Gateway Ns Env Services Get | |
type: array | |
items: | |
$ref: '#/components/schemas/ServiceListItem' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
post: | |
tags: | |
- Gateway | |
summary: Attach Service | |
description: |- | |
将服务发布到指定环境 | |
:return: | |
operationId: attach_service_api_gateway__ns___env__services_post | |
parameters: | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
- required: true | |
schema: | |
title: Service ID to attach | |
type: integer | |
name: service_id | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/gateway/{ns}/{env}/services/{sid}': | |
post: | |
tags: | |
- Gateway | |
summary: Handle Env Service Application | |
description: |- | |
处理服务部署到网关的申请 | |
:return: | |
operationId: handle_env_service_application_api_gateway__ns___env__services__sid__post | |
parameters: | |
- required: true | |
schema: | |
title: Service ID | |
type: integer | |
name: sid | |
in: path | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
- required: true | |
schema: | |
title: Action to take | |
type: string | |
name: action | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Gateway | |
summary: Detach Env Service | |
description: |- | |
将服务从环境删除 | |
:return: | |
operationId: detach_env_service_api_gateway__ns___env__services__sid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Service ID to detach | |
type: integer | |
name: sid | |
in: path | |
- required: true | |
schema: | |
title: Namespace | |
type: string | |
name: ns | |
in: path | |
- required: true | |
schema: | |
title: Env name | |
type: string | |
name: env | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/team/new: | |
post: | |
tags: | |
- Team | |
summary: New Team | |
description: |- | |
创建团队 | |
:return: | |
operationId: new_team_api_team_new_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateTeamRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/TeamInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/team/{name}/invite': | |
post: | |
tags: | |
- Team | |
summary: Invite Member | |
description: |- | |
邀请成员 | |
:return: | |
operationId: invite_member_api_team__name__invite_post | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/InvitationRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/InvitationInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/team/{name}/member/{uid}': | |
post: | |
tags: | |
- Team | |
summary: Change Role | |
description: |- | |
设置团队成员角色 | |
:return: | |
operationId: change_role_api_team__name__member__uid__post | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: User ID | |
type: integer | |
name: uid | |
in: path | |
- required: true | |
schema: | |
title: User role | |
type: string | |
name: role | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
delete: | |
tags: | |
- Team | |
summary: Kick Member | |
description: |- | |
删除团队成员 | |
:return: | |
operationId: kick_member_api_team__name__member__uid__delete | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
- required: true | |
schema: | |
title: User ID | |
type: integer | |
name: uid | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: {} | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/team/{name}/info': | |
get: | |
tags: | |
- Team | |
summary: Team Info | |
description: |- | |
团队信息页面 | |
:return: | |
operationId: team_info_api_team__name__info_get | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/TeamInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
'/api/team/{name}/members': | |
get: | |
tags: | |
- Team | |
summary: Team Members | |
description: |- | |
获取团队成员列表 | |
:return: | |
operationId: team_members_api_team__name__members_get | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Team Members Api Team Name Members Get | |
type: array | |
items: | |
$ref: '#/components/schemas/TeamMember' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/team/{name}/services': | |
get: | |
tags: | |
- Team | |
summary: Team Services | |
description: |- | |
团队创建的服务列表 | |
:return: | |
operationId: team_services_api_team__name__services_get | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Team Services Api Team Name Services Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicServiceInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/team/{name}/apps': | |
get: | |
tags: | |
- Team | |
summary: Team Apps | |
description: |- | |
获取团队创建的应用列表 | |
:return: | |
operationId: team_apps_api_team__name__apps_get | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Team Apps Api Team Name Apps Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicAppInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/team/{name}/envs': | |
get: | |
tags: | |
- Team | |
summary: Team Envs | |
description: |- | |
获取团队创建的环境列表 | |
:return: | |
operationId: team_envs_api_team__name__envs_get | |
parameters: | |
- required: true | |
schema: | |
title: Team name | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Team Envs Api Team Name Envs Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicEnvInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
/api/user/register: | |
post: | |
tags: | |
- User | |
summary: Register User | |
description: |- | |
新用户注册 | |
:return: | |
operationId: register_user_api_user_register_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/CreateUserRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/UserProfile' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/user/{name}/info': | |
get: | |
tags: | |
- User | |
summary: User Info | |
description: |- | |
查看其他用户的信息 | |
:return: | |
operationId: user_info_api_user__name__info_get | |
parameters: | |
- required: true | |
schema: | |
title: Username | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PublicUserInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/user/{name}/services': | |
get: | |
tags: | |
- User | |
summary: User Services | |
description: |- | |
查看其他用户管理的service | |
:return: | |
operationId: user_services_api_user__name__services_get | |
parameters: | |
- required: true | |
schema: | |
title: Username | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response User Services Api User Name Services Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicServiceInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/user/{name}/apps': | |
get: | |
tags: | |
- User | |
summary: User Apps | |
description: |- | |
查看其他用户管理的app | |
:return: | |
operationId: user_apps_api_user__name__apps_get | |
parameters: | |
- required: true | |
schema: | |
title: Username | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response User Apps Api User Name Apps Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicAppInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
'/api/user/{name}/teams': | |
get: | |
tags: | |
- User | |
summary: User Teams | |
description: |- | |
查看其他用户所属的team | |
:return: | |
operationId: user_teams_api_user__name__teams_get | |
parameters: | |
- required: true | |
schema: | |
title: Username | |
type: string | |
name: name | |
in: path | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response User Teams Api User Name Teams Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicTeamInfo' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
/api/user/my_profile: | |
get: | |
tags: | |
- User | |
summary: Get My Profile | |
description: |- | |
查看我的个人信息 | |
:return: | |
operationId: get_my_profile_api_user_my_profile_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/UserProfile' | |
security: | |
- OAuth2PasswordBearer: [] | |
post: | |
tags: | |
- User | |
summary: Edit My Profile | |
description: ':return:' | |
operationId: edit_my_profile_api_user_my_profile_post | |
requestBody: | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/EditUserProfileRequest' | |
required: true | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/UserProfile' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/user/my_services: | |
get: | |
tags: | |
- User | |
summary: Get My Services | |
description: |- | |
返回我创建的服务和我有管理员权限的团队的服务 | |
:return: | |
operationId: get_my_services_api_user_my_services_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get My Services Api User My Services Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicServiceInfo' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/user/my_teams: | |
get: | |
tags: | |
- User | |
summary: Get My Teams | |
description: |- | |
我所属的团队 | |
:return: | |
operationId: get_my_teams_api_user_my_teams_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get My Teams Api User My Teams Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicTeamInfo' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/user/my_apps: | |
get: | |
tags: | |
- User | |
summary: Get My Apps | |
description: ':return:' | |
operationId: get_my_apps_api_user_my_apps_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get My Apps Api User My Apps Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicAppInfo' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/user/my_envs: | |
get: | |
tags: | |
- User | |
summary: Get My Envs | |
description: ':return:' | |
operationId: get_my_envs_api_user_my_envs_get | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
title: Response Get My Envs Api User My Envs Get | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicEnvInfo' | |
security: | |
- OAuth2PasswordBearer: [] | |
/api/portal/catalog: | |
get: | |
tags: | |
- Portal | |
summary: Catalog | |
description: |- | |
服务列表 | |
:return: | |
operationId: catalog_api_portal_catalog_get | |
parameters: | |
- required: true | |
schema: | |
title: Tag | |
type: string | |
name: tag | |
in: query | |
- required: true | |
schema: | |
title: Sort | |
type: string | |
name: sort | |
in: query | |
- required: true | |
schema: | |
title: Page | |
type: integer | |
name: page | |
in: query | |
- required: true | |
schema: | |
title: Limit | |
type: integer | |
name: limit | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PagedResult_PublicServiceInfo_' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
/api/portal/search: | |
get: | |
tags: | |
- Portal | |
summary: Search | |
description: |- | |
服务搜索 | |
:return: | |
operationId: search_api_portal_search_get | |
parameters: | |
- required: true | |
schema: | |
title: Kw | |
type: string | |
name: kw | |
in: query | |
- required: true | |
schema: | |
title: Page | |
type: integer | |
name: page | |
in: query | |
- required: true | |
schema: | |
title: Limit | |
type: integer | |
name: limit | |
in: query | |
responses: | |
'200': | |
description: Successful Response | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/PagedResult_PublicServiceInfo_' | |
'422': | |
description: Validation Error | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/HTTPValidationError' | |
components: | |
schemas: | |
AccessToken: | |
title: AccessToken | |
required: | |
- access_token | |
- token_type | |
type: object | |
properties: | |
access_token: | |
title: Access Token | |
type: string | |
token_type: | |
title: Token Type | |
type: string | |
example: | |
access_token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6InpoYW5nbGhAdGhpbmstbGFuZC5jb20iLCJleHAiOjE1MTYyMzkwMjJ9.XarZTSHg7bN3Si80R-G4btGPA6FiqYPIDCNbvmxtlsg | |
token_type: Bearer | |
Body_login_for_access_token_oauth2_token_post: | |
title: Body_login_for_access_token_oauth2_token_post | |
required: | |
- username | |
- password | |
type: object | |
properties: | |
grant_type: | |
title: Grant Type | |
pattern: password | |
type: string | |
username: | |
title: Username | |
type: string | |
password: | |
title: Password | |
type: string | |
scope: | |
title: Scope | |
type: string | |
default: '' | |
client_id: | |
title: Client Id | |
type: string | |
client_secret: | |
title: Client Secret | |
type: string | |
CreateAppRequest: | |
title: CreateAppRequest | |
required: | |
- namespace | |
- app_name | |
- description | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
app_name: | |
title: App Name | |
type: string | |
description: | |
title: Description | |
type: string | |
CreateEnvRequest: | |
title: CreateEnvRequest | |
required: | |
- namespace | |
- env_name | |
- endpoint | |
- description | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
env_name: | |
title: Env Name | |
type: string | |
endpoint: | |
title: Endpoint | |
type: string | |
description: | |
title: Description | |
type: string | |
CreatePolicyRequest: | |
title: CreatePolicyRequest | |
required: | |
- methods | |
- path_pattern | |
- filter_type | |
- settings | |
type: object | |
properties: | |
methods: | |
title: Methods | |
type: string | |
path_pattern: | |
title: Path Pattern | |
type: string | |
filter_type: | |
title: Filter Type | |
type: string | |
settings: | |
title: Settings | |
type: object | |
is_active: | |
title: Is Active | |
type: boolean | |
CreateServiceLevelRequest: | |
title: CreateServiceLevelRequest | |
required: | |
- name | |
- auto_approve | |
type: object | |
properties: | |
name: | |
title: Name | |
type: string | |
auto_approve: | |
title: Auto Approve | |
type: boolean | |
CreateServiceRequest: | |
title: CreateServiceRequest | |
required: | |
- namespace | |
- service_name | |
- description | |
- listen_path | |
- auth_type | |
- upstreams | |
- rate_limit | |
- auto_approve | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
service_name: | |
title: Service Name | |
type: string | |
description: | |
title: Description | |
type: string | |
spec_url: | |
title: Spec Url | |
type: string | |
listen_path: | |
title: Listen Path | |
type: string | |
auth_type: | |
title: Auth Type | |
type: string | |
upstreams: | |
title: Upstreams | |
type: array | |
items: | |
type: string | |
rate_limit: | |
title: Rate Limit | |
type: integer | |
auto_approve: | |
title: Auto Approve | |
type: boolean | |
CreateTeamRequest: | |
title: CreateTeamRequest | |
required: | |
- team_name | |
- is_public | |
- description | |
type: object | |
properties: | |
team_name: | |
title: Team Name | |
type: string | |
is_public: | |
title: Is Public | |
type: boolean | |
description: | |
title: Description | |
type: string | |
CreateUpstreamRequest: | |
title: CreateUpstreamRequest | |
required: | |
- upstream | |
- status | |
- route_criteria | |
- route_prob | |
- route_fuse | |
type: object | |
properties: | |
upstream: | |
title: Upstream | |
type: string | |
status: | |
title: Status | |
type: string | |
route_criteria: | |
title: Route Criteria | |
type: string | |
route_prob: | |
title: Route Prob | |
type: number | |
route_fuse: | |
title: Route Fuse | |
type: string | |
CreateUserRequest: | |
title: CreateUserRequest | |
required: | |
- username | |
- password | |
- invite_code | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
username: | |
title: Username | |
type: string | |
password: | |
title: Password | |
type: string | |
invite_code: | |
title: Invite Code | |
type: string | |
EditUserProfileRequest: | |
title: EditUserProfileRequest | |
required: | |
- display_name | |
- avatar | |
- company | |
- website | |
- lang | |
- location | |
- bio | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
display_name: | |
title: Display Name | |
type: string | |
avatar: | |
title: Avatar | |
type: string | |
company: | |
title: Company | |
type: string | |
website: | |
title: Website | |
type: string | |
lang: | |
title: Lang | |
type: string | |
location: | |
title: Location | |
type: string | |
bio: | |
title: Bio | |
type: string | |
EnvInfo: | |
title: EnvInfo | |
required: | |
- id | |
- namespace | |
- env_name | |
- description | |
- endpoint | |
- uptime | |
- services_count | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
namespace: | |
title: Namespace | |
type: string | |
env_name: | |
title: Env Name | |
type: string | |
description: | |
title: Description | |
type: string | |
endpoint: | |
title: Endpoint | |
type: string | |
uptime: | |
title: Uptime | |
type: integer | |
services_count: | |
title: Services Count | |
type: integer | |
HTTPValidationError: | |
title: HTTPValidationError | |
type: object | |
properties: | |
detail: | |
title: Detail | |
type: array | |
items: | |
$ref: '#/components/schemas/ValidationError' | |
InvitationInfo: | |
title: InvitationInfo | |
required: | |
- role | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
role: | |
title: Role | |
anyOf: | |
- const: admin | |
type: string | |
- const: member | |
type: string | |
InvitationRequest: | |
title: InvitationRequest | |
required: | |
- role | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
role: | |
title: Role | |
anyOf: | |
- const: admin | |
type: string | |
- const: member | |
type: string | |
PagedResult_PublicServiceInfo_: | |
title: 'PagedResult[PublicServiceInfo]' | |
required: | |
- total | |
- limit | |
- offset | |
- items | |
type: object | |
properties: | |
total: | |
title: Total | |
type: integer | |
limit: | |
title: Limit | |
type: integer | |
offset: | |
title: Offset | |
type: integer | |
items: | |
title: Items | |
type: array | |
items: | |
$ref: '#/components/schemas/PublicServiceInfo' | |
PagedResult_ServiceClientAuth_: | |
title: 'PagedResult[ServiceClientAuth]' | |
required: | |
- total | |
- limit | |
- offset | |
- items | |
type: object | |
properties: | |
total: | |
title: Total | |
type: integer | |
limit: | |
title: Limit | |
type: integer | |
offset: | |
title: Offset | |
type: integer | |
items: | |
title: Items | |
type: array | |
items: | |
$ref: '#/components/schemas/ServiceClientAuth' | |
Policy: | |
title: Policy | |
required: | |
- id | |
- method | |
- path_regex | |
- policy_type | |
- policy_setting | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
method: | |
title: Method | |
type: string | |
path_regex: | |
title: Path Regex | |
type: string | |
policy_type: | |
title: Policy Type | |
type: string | |
policy_setting: | |
title: Policy Setting | |
type: string | |
PublicAppInfo: | |
title: PublicAppInfo | |
required: | |
- namespace | |
- app_name | |
- description | |
- service_count | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
app_name: | |
title: App Name | |
type: string | |
description: | |
title: Description | |
type: string | |
service_count: | |
title: Service Count | |
type: integer | |
PublicEnvInfo: | |
title: PublicEnvInfo | |
required: | |
- namespace | |
- env_name | |
- description | |
- endpoint | |
- uptime | |
- service_count | |
- app_count | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
env_name: | |
title: Env Name | |
type: string | |
description: | |
title: Description | |
type: string | |
endpoint: | |
title: Endpoint | |
type: string | |
uptime: | |
title: Uptime | |
type: integer | |
service_count: | |
title: Service Count | |
type: integer | |
app_count: | |
title: App Count | |
type: integer | |
PublicServiceInfo: | |
title: PublicServiceInfo | |
required: | |
- namespace | |
- service_name | |
- description | |
- protocol | |
- env | |
- uptime | |
- total_requests | |
- upstream_count | |
- client_count | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
service_name: | |
title: Service Name | |
type: string | |
description: | |
title: Description | |
type: string | |
protocol: | |
title: Protocol | |
type: string | |
env: | |
title: Env | |
type: string | |
uptime: | |
title: Uptime | |
type: integer | |
total_requests: | |
title: Total Requests | |
type: integer | |
upstream_count: | |
title: Upstream Count | |
type: integer | |
client_count: | |
title: Client Count | |
type: integer | |
PublicTeamInfo: | |
title: PublicTeamInfo | |
required: | |
- team_name | |
- description | |
- app_count | |
- member_count | |
- env_count | |
- service_count | |
- is_public | |
type: object | |
properties: | |
team_name: | |
title: Team Name | |
type: string | |
description: | |
title: Description | |
type: string | |
app_count: | |
title: App Count | |
type: integer | |
member_count: | |
title: Member Count | |
type: integer | |
env_count: | |
title: Env Count | |
type: integer | |
service_count: | |
title: Service Count | |
type: integer | |
is_public: | |
title: Is Public | |
type: boolean | |
PublicUserInfo: | |
title: PublicUserInfo | |
required: | |
- username | |
- display_name | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
username: | |
title: Username | |
type: string | |
display_name: | |
title: Display Name | |
type: string | |
avatar: | |
title: Avatar | |
type: string | |
SaveAppInfo: | |
title: SaveAppInfo | |
required: | |
- description | |
type: object | |
properties: | |
description: | |
title: Description | |
type: string | |
SaveEnvInfo: | |
title: SaveEnvInfo | |
required: | |
- endpoint | |
- description | |
type: object | |
properties: | |
endpoint: | |
title: Endpoint | |
type: string | |
description: | |
title: Description | |
type: string | |
ServiceApplyRequest: | |
title: ServiceApplyRequest | |
required: | |
- client_id | |
- sla_id | |
type: object | |
properties: | |
client_id: | |
title: Client Id | |
type: integer | |
sla_id: | |
title: Sla Id | |
type: integer | |
ServiceBasicInfo: | |
title: ServiceBasicInfo | |
required: | |
- namespace | |
- service_name | |
- description | |
type: object | |
properties: | |
namespace: | |
title: Namespace | |
type: string | |
service_name: | |
title: Service Name | |
type: string | |
description: | |
title: Description | |
type: string | |
ServiceClient: | |
title: ServiceClient | |
required: | |
- id | |
- client_name | |
- description | |
- icon | |
- app_key | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
client_name: | |
title: Client Name | |
type: string | |
description: | |
title: Description | |
type: string | |
icon: | |
title: Icon | |
type: string | |
app_key: | |
title: App Key | |
type: string | |
ServiceClientAuth: | |
title: ServiceClientAuth | |
required: | |
- id | |
- client_name | |
- description | |
- sla_name | |
- sla_id | |
- status | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
client_name: | |
title: Client Name | |
type: string | |
description: | |
title: Description | |
type: string | |
sla_name: | |
title: Sla Name | |
type: string | |
sla_id: | |
title: Sla Id | |
type: integer | |
status: | |
title: Status | |
type: string | |
ServiceClientKey: | |
title: ServiceClientKey | |
required: | |
- app_key | |
- app_secret | |
type: object | |
properties: | |
app_key: | |
title: App Key | |
type: string | |
app_secret: | |
title: App Secret | |
type: string | |
ServiceInfo: | |
title: ServiceInfo | |
required: | |
- id | |
- namespace | |
- ns_type | |
- service_name | |
- listen_path | |
- auth_type | |
- protocol | |
- description | |
- client_count | |
- upstream_count | |
- status | |
- my_role | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
namespace: | |
title: Namespace | |
maxLength: 30 | |
minLength: 4 | |
type: string | |
ns_type: | |
title: Ns Type | |
anyOf: | |
- const: User | |
type: string | |
- const: Team | |
type: string | |
service_name: | |
title: Service Name | |
maxLength: 30 | |
minLength: 5 | |
type: string | |
api_spec: | |
title: Api Spec | |
maxLength: 2083 | |
minLength: 1 | |
type: string | |
format: uri | |
listen_path: | |
title: Listen Path | |
maxLength: 30 | |
minLength: 3 | |
type: string | |
auth_type: | |
title: Auth Type | |
anyOf: | |
- const: appkey | |
type: string | |
- const: jwt | |
type: string | |
- const: oauth2 | |
type: string | |
protocol: | |
title: Protocol | |
anyOf: | |
- const: http | |
type: string | |
- const: grpc | |
type: string | |
description: | |
title: Description | |
maxLength: 255 | |
minLength: 1 | |
type: string | |
env: | |
title: Env | |
type: string | |
client_count: | |
title: Client Count | |
type: integer | |
upstream_count: | |
title: Upstream Count | |
type: integer | |
status: | |
title: Status | |
anyOf: | |
- const: 'on' | |
type: string | |
- const: 'off' | |
type: string | |
my_role: | |
title: My Role | |
anyOf: | |
- const: owner | |
type: string | |
- const: admin | |
type: string | |
- const: member | |
type: string | |
example: | |
id: 1 | |
namespace: leric | |
ns_type: User | |
service_name: account | |
api_spec: 'http://127.0.0.1:5000/openapi.json' | |
listen_path: account | |
auth_type: appkey | |
protocol: http | |
description: test api | |
client_count: 3 | |
upstream_count: 1 | |
status: 'on' | |
my_role: owner | |
ServiceListItem: | |
title: ServiceListItem | |
required: | |
- service_id | |
- namespace | |
- service_name | |
type: object | |
properties: | |
service_id: | |
title: Service Id | |
type: integer | |
namespace: | |
title: Namespace | |
type: string | |
service_name: | |
title: Service Name | |
type: string | |
ServiceSLA: | |
title: ServiceSLA | |
required: | |
- id | |
- level_name | |
- auto_approve | |
- policies | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
level_name: | |
title: Level Name | |
type: string | |
auto_approve: | |
title: Auto Approve | |
type: boolean | |
policies: | |
title: Policies | |
type: array | |
items: | |
$ref: '#/components/schemas/Policy' | |
ServiceUpstream: | |
title: ServiceUpstream | |
required: | |
- id | |
- upstream | |
- status | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
upstream: | |
title: Upstream | |
maxLength: 65536 | |
minLength: 1 | |
type: string | |
format: uri | |
status: | |
title: Status | |
anyOf: | |
- const: 'on' | |
type: string | |
- const: 'off' | |
type: string | |
- const: canary | |
type: string | |
revision: | |
title: Revision | |
type: string | |
route_criteria: | |
title: Route Criteria | |
type: string | |
route_prob: | |
title: Route Prob | |
type: number | |
StatsSeries: | |
title: StatsSeries | |
type: object | |
properties: {} | |
TeamInfo: | |
title: TeamInfo | |
required: | |
- id | |
- team_name | |
- description | |
- visibility | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
team_name: | |
title: Team Name | |
maxLength: 30 | |
minLength: 4 | |
type: string | |
description: | |
title: Description | |
maxLength: 255 | |
minLength: 1 | |
type: string | |
visibility: | |
title: Visibility | |
anyOf: | |
- const: public | |
type: string | |
- const: private | |
type: string | |
example: | |
id: 1 | |
team_name: devops | |
description: Ops Team | |
visibility: public | |
TeamMember: | |
title: TeamMember | |
required: | |
- user_id | |
- username | |
- role | |
type: object | |
properties: | |
user_id: | |
title: User Id | |
type: integer | |
username: | |
title: Username | |
maxLength: 30 | |
minLength: 4 | |
type: string | |
role: | |
title: Role | |
anyOf: | |
- const: owner | |
type: string | |
- const: admin | |
type: string | |
- const: member | |
type: string | |
example: | |
user_id: 1 | |
username: leric | |
role: owner | |
UserProfile: | |
title: UserProfile | |
required: | |
- username | |
- display_name | |
- language | |
type: object | |
properties: | |
email: | |
title: Email | |
type: string | |
username: | |
title: Username | |
type: string | |
display_name: | |
title: Display Name | |
type: string | |
avatar: | |
title: Avatar | |
type: string | |
company: | |
title: Company | |
type: string | |
website: | |
title: Website | |
type: string | |
language: | |
title: Language | |
type: string | |
location: | |
title: Location | |
type: string | |
bio: | |
title: Bio | |
type: string | |
UserToken: | |
title: UserToken | |
required: | |
- id | |
- username | |
- display_name | |
- is_active | |
type: object | |
properties: | |
id: | |
title: Id | |
type: integer | |
username: | |
title: Username | |
maxLength: 30 | |
minLength: 4 | |
type: string | |
email: | |
title: Email | |
type: string | |
format: email | |
display_name: | |
title: Display Name | |
maxLength: 30 | |
minLength: 4 | |
type: string | |
is_active: | |
title: Is Active | |
type: boolean | |
example: | |
id: 1 | |
username: leric | |
email: [email protected] | |
display_name: Leric Zhang | |
is_active: true | |
ValidationError: | |
title: ValidationError | |
required: | |
- loc | |
- msg | |
- type | |
type: object | |
properties: | |
loc: | |
title: Location | |
type: array | |
items: | |
type: string | |
msg: | |
title: Message | |
type: string | |
type: | |
title: Error Type | |
type: string | |
securitySchemes: | |
OAuth2PasswordBearer: | |
type: oauth2 | |
flows: | |
password: | |
scopes: {} | |
tokenUrl: oauth2/token |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment