Palbase Auth API · API
/admin/oauth-clientsRegister an OAuth client
Registers a client (a web app, a CLI, a partner) of this project's OpenID provider. The client secret of a confidential client is returned once, in this response, and can never be read again; a public client has none. The create is recorded with its answer: a retry with the same Idempotency-Key gets the same client and secret back, never a second client.
Called by your server, with the project's secret key.
Headers
Idempotency-Keystring · optionalMakes the create safe to send again (at most 255 characters). A retry with the same key and the same request gets the first answer back, marked `Idempotent-Replayed: true`, instead of a second resource; the same key with a different request is refused with 422, and while the first request still runs a retry gets 409 with Retry-After.Request body
client_idstring · optionalA stable client_id to use verbatim (e.g. for first-party tooling); absent: a random `oidc_…` id.client_namestring · requireddpop_bound_access_tokensboolean · optionalRFC 9449 §5.2: the client always proves a key. A token request without a DPoP proof is refused, and so is a public client's authorization request without dpop_jkt. Absent: false.grant_types"authorization_code" | "refresh_token" | "client_credentials" | "urn:ietf:params:oauth:grant-type:device_code"[] · optionalAbsent or empty: [authorization_code].id_token_lifetime_secsinteger (int32) · optionalAbsent or 0: 3600.is_publicboolean · optionalA public client has no secret.jwksobject · optionalThe public keys a private_key_jwt client signs its assertions with.post_logout_redirect_urisstring[] · optionalredirect_urisstring[] · optionalresponse_types"code"[] · optionalAbsent or empty: [code].scopesstring[] · optionalAbsent or empty: [openid, profile, email].token_endpoint_auth_method"client_secret_basic" | "client_secret_post" | "private_key_jwt" | "none" · optionalAbsent: none for a public client, client_secret_basic otherwise. private_key_jwt needs jwks and issues no secret.curl -X POST "https://<your-ref>.palbase.studio/admin/oauth-clients" \
-H "apikey: $PALBASE_SECRET_KEY" \
-H "content-type: application/json" \
-d '{"client_name":"string"}'Responses
201The client, with its secret
400Validation failed or required field missing
401Missing, invalid, or expired credentials
403Not permitted with this key; or the project is the platform's own (`owner_only`): every change on its admin surface — any account's address, password, factors, sessions or roles, an account made or imported, a sign-in minted, a setting — is its owner's or its operator's alone. The request carries, besides the project's key, the owner's access token (X-Palbase-Owner; a passkey sign-in of the last 15 minutes, else 401 `insufficient_user_authentication`) or the operator's token (X-Palbase-Operator). Its key reads.
409Another client has this client_id (`client_id_taken`), or the Idempotency-Key is in use.
413A request carrying an Idempotency-Key is larger than 1 MiB
422The Idempotency-Key was already used with a different request
503Downstream dependency unavailable (typically HIBP / breach service)
defaultAn error: the envelope names it (`error`) and explains it (`error_description`).
Operation AdminCreateOAuthClient of auth's contract.