POST /internal/oauth/clients

内部API,由 tenant-service 在创建新租户时调用,为租户注册默认 OAuth 客户端。受 InternalAPIKeyAuth + ExtractTenantFromHeaderStrict 保护。

OAuth - 内部接口 None application/json

请求体

Schema: service-oauth/internal/handler/dto.CreateClientRequest

字段类型必填示例约束描述
name string 是
redirect_uris array of

string

是 items: 1–None
alias string 否 Alias 显示简称(可选):前台列表优先展示,空则用 Name。
client_auth_methods array of

string

否
cors_origins array of

string

否
fapi_profile string 否
grant_types array of

string

否
is_confidential boolean 否
jwks string 否
jwks_uri string 否
logo_url string 否
post_logout_redirect_uris array of

string

否
privacy_policy string 否
scopes array of

string

否
terms_url string 否
website string 否

响应

引用的 Schema

dto.DataResponse-service-oauth/internal/handler/dto/CreateClientResponse

字段类型必填示例约束描述
code integer 否
data service-oauth/internal/handler/dto.CreateClientResponse 否
message string 否
timestamp string 否

service-core/base/dto.SimpleResponse

字段类型必填示例约束描述
code integer 否
message string 否
timestamp string 否

service-oauth/internal/handler/dto.CreateClientResponse

OAuth客户端创建结果

字段类型必填示例约束描述
client_auth_methods string 否 ["client_secret_basic","private_key_jwt"]
client_id string 否 app-123
client_secret string 否 secret_abc123
cors_origins array of

string

否 ['["https://app.example.com"]']
fapi_profile string 否 fapi1
grant_types array of

string

否 ['["authorization_code"', '"refresh_token"]']
id string 否 01JNXXXXX...
is_confidential boolean 否 True
jwks string 否
jwks_uri string 否 https://client.example.com/.well-known/jwks.json
logo_url string 否 https://app.example.com/logo.png
name string 否 My Application
post_logout_redirect_uris array of

string

否 ['["https://app.example.com/"]'] PostLogoutRedirectURIs 登出回跳白名单(OIDC RP-Initiated Logout 1.0 独立注册面,ADR-1)
privacy_policy string 否 https://app.example.com/privacy
redirect_uris array of

string

否 ['["https://app.example.com/callback"]']
scopes array of

string

否 ['["openid"', '"profile"', '"email"]']
status string 否 active
terms_url string 否 https://app.example.com/terms
website string 否 https://app.example.com