Storyden
Admin

Admin O Auth Client Create

Create an OAuth client. Confidential clients receive a generated secret once at creation time and must authenticate to `/oauth/token` when using confidential grants. Public clients do not receive or use a client secret.

Create an OAuth client.

Confidential clients receive a generated secret once at creation time and must authenticate to /oauth/token when using confidential grants. Public clients do not receive or use a client secret.

POST/admin/oauth/clients
storyden-session<token>

In: cookie

Request Body

application/json

account_id*string

A unique identifier for this resource.

Formatxid
client_id*string
client_secret_hash?string
name*string
type*string
Value in"public" | "confidential"
scope_policy?string
Value in"explicit" | "inherit"
redirect_uris*array<>
allowed_scopes*array<>
allowed_grants*array<>

Response Body

application/json

application/json

curl -X POST "https://loading/api/admin/oauth/clients" \  -H "Content-Type: application/json" \  -d '{    "account_id": "cc5lnd2s1s4652adtu50",    "client_id": "string",    "name": "string",    "type": "public",    "redirect_uris": [      "http://example.com"    ],    "allowed_scopes": [      "string"    ],    "allowed_grants": [      "string"    ]  }'
{
  "id": "cc5lnd2s1s4652adtu50",
  "createdAt": "2019-08-24T14:15:22Z",
  "updatedAt": "2019-08-24T14:15:22Z",
  "account_id": "cc5lnd2s1s4652adtu50",
  "client_id": "string",
  "name": "string",
  "type": "public",
  "scope_policy": "explicit",
  "redirect_uris": [
    "http://example.com"
  ],
  "allowed_scopes": [
    "string"
  ],
  "allowed_grants": [
    "string"
  ]
}
Empty
Empty
{
  "error": "string",
  "message": "string",
  "suggested": "string",
  "metadata": {}
}