Accounts & authentication
Register a public OAuth client
POST /oauth/register
Registers a public client with one to ten HTTPS or loopback HTTP redirect URIs. Only authorization_code and refresh_token grants, the code response and token_endpoint_auth_method none are supported. Client names are self-declared and cannot contain control, format, tag, line or paragraph separator characters or double quotes. Registrations that never obtain a grant are swept after one day unless a live authorization request names them. Registration errors use OAuth client-registration JSON. A 429 can be an OAuth error from registration limits or a problem from the shared address limit; both carry Retry-After.
Parameters
Idempotency-Keyheader · optional · stringMakes a retry safe: a request with the same key and the same method, path, and body as an earlier one gets the earlier response instead of doing the work again. 1 to 255 visible ASCII characters; use a new key for each new request, such as a UUID. Keys are kept per caller for a day, and ignored for requests without credentials.
Minimum length:
1· Maximum length:255
Example request
curl --request POST 'https://commitscale.com/oauth/register' \
--header 'Content-Type: application/json' \
--data '{
"redirect_uris": [
"example"
]
}'Example values illustrate the format. Use your own credentials and identifiers.
Request body
application/json
application_typeoptional · stringWeb or native. Defaults to web.
client_nameoptional · stringSelf-declared, at most 100 characters. No control, format, tag, separator or double-quote characters.
grant_typesoptional · array of stringAuthorization code and optionally refresh token. Defaults to authorization code.
Fields of
grant_typesAuthorization code and optionally refresh token. Defaults to authorization code.
Each item has this shape.
redirect_urisrequired · array of stringOne to ten HTTPS or loopback HTTP redirect URIs.
Fields of
redirect_urisOne to ten HTTPS or loopback HTTP redirect URIs.
Each item has this shape.
response_typesoptional · array of stringThe supported response type is code.
Fields of
response_typesThe supported response type is code.
Each item has this shape.
token_endpoint_auth_methodoptional · stringPublic clients use none.
Responses
201 The registered client metadata.
application/json
{
"application_type": "example",
"client_id": "example",
"client_id_issued_at": 1,
"client_name": "example",
"grant_types": [
"example"
],
"redirect_uris": [
"example"
],
"response_types": [
"example"
],
"token_endpoint_auth_method": "example"
}application_typerequired · stringWeb or native.
client_idrequired · stringThe public client's identifier.
client_id_issued_atrequired · integer (int64)When the identifier was issued, in Unix seconds.
client_namerequired · stringThe client's self-declared name.
grant_typesrequired · array of stringThe registered grant types.
Fields of
grant_typesThe registered grant types.
Each item has this shape.
redirect_urisrequired · array of stringThe registered redirect URIs.
Fields of
redirect_urisThe registered redirect URIs.
Each item has this shape.
response_typesrequired · array of stringThe registered response types.
Fields of
response_typesThe registered response types.
Each item has this shape.
token_endpoint_auth_methodrequired · stringPublic clients use none.
RateLimit and RateLimit-Policy describe the request rate. Follow Retry-After when a response asks you to wait.
Problem responses
Errors use application/problem+json. Act on the stable code, and follow next when present. See the problem format.
quota_exceeded429With 429, the caller used its requests for the minute. With 422, a count limit was reached.
With 429, wait
Retry-Afterseconds and retry. With 422, remove one first.