palbaseDocs

Palbase Auth API · API

PATCH/admin/oauth-clients/{id}

Update an OAuth client

Changes a client's settings — its name, where it may redirect, what it may ask for, how it authenticates, whether its tokens are DPoP-bound. The result passes the same checks a new client does; an invalid one is 400 and changes nothing.

Called by your server, with the project's secret key.

Path

idstring · requiredThe client's internal id (`oc_…`).

Request body

client_namestring · optional
dpop_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"[] · optional
id_token_lifetime_secsinteger (int32) · optional
jwksobject · optionalThe public keys a private_key_jwt client signs its assertions with.
post_logout_redirect_urisstring[] · optional
redirect_urisstring[] · optional
response_types"code"[] · optional
scopesstring[] · optional
token_endpoint_auth_method"client_secret_basic" | "client_secret_post" | "private_key_jwt" | "none" · optionalA secret client may move to private_key_jwt (with jwks), giving up its secret; a private_key_jwt client cannot move back.
curl
curl -X PATCH "https://<your-ref>.palbase.studio/admin/oauth-clients/<id>" \
  -H "apikey: $PALBASE_SECRET_KEY" \
  -H "content-type: application/json" \
  -d '{"client_name":"string","dpop_bound_access_tokens":false,"grant_types":["authorization_code"],"id_token_lifetime_secs":0,"jwks":{"keys":[{"kid":"string","kty":"RSA"}]},"post_logout_redirect_uris":["string"],"redirect_uris":["string"],"response_types":["code"],"scopes":["string"],"token_endpoint_auth_method":"client_secret_basic"}'

Responses

200The client as it now is

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.

404Resource does not exist or is not visible to the caller

503Downstream dependency unavailable (typically HIBP / breach service)

defaultAn error: the envelope names it (`error`) and explains it (`error_description`).

Operation AdminUpdateOAuthClient of auth's contract.