API reference

OAuth clients

The three ways an MCP client gets a client id: dynamic registration, a client ID metadata document, or registration by the app.

Every client is public: no client secret, PKCE required. A client has one of three kinds:

kindHow it is createdclient_id
dynamicThe client registers itself at register (RFC 7591).dcr_ and 24 characters
metadata_documentThe client uses an https URL as its client_id. Scute fetches the JSON document at that URL on first use.The URL
registeredThe app's backend creates it with POST /v1/apps/:app_id/oauth/clients.cli_ and 24 characters

Redirect URIs: 1 to 20 per client. Each is an https URL, an http URL on a loopback host (127.0.0.1, localhost, ::1), or an app scheme such as cursor://callback. No fragments. The schemes javascript, data, file, vbscript, about, blob, ftp, ws and wss are refused.

Register a client#

POST/v1/oauth/:app_id/registerNone

Dynamic client registration. Returns 404 with error_code not_found when the app has turned it off (dynamic_registration in the server settings). Limited to 20 registrations per hour per IP.

redirect_urisstring[]required
1 to 20 redirect URIs.
client_namestring
Shown on the consent page. Up to 100 characters are kept.
client_uristring
An https URL. Other values are dropped.
logo_uristring
An https URL. Other values are dropped.
token_endpoint_auth_methodstring
none, the default. Any other value returns invalid_client_metadata.
grant_typesstring[]
A subset of authorization_code and refresh_token. Default both.
cURLbash
curl -X POST https://api.scute.io/v1/oauth/app_3mxZRrzWxhPZ08dXvqq6/register \  -H "Content-Type: application/json" \  -d '{"client_name": "My MCP client", "redirect_uris": ["http://127.0.0.1:33418/callback"]}'
Response 201json
{  "client_id": "dcr_xxxxxxxxxxxxxxxxxxxxxxxx",  "client_id_issued_at": 1763460000,  "client_name": "My MCP client",  "redirect_uris": ["http://127.0.0.1:33418/callback"],  "token_endpoint_auth_method": "none",  "grant_types": ["authorization_code", "refresh_token"],  "response_types": ["code"]}
StatuserrorWhen
400invalid_client_metadataA confidential client or an unsupported grant type.
400invalid_redirect_uriMissing or invalid redirect URIs.

Client ID metadata documents#

When client_metadata_documents is on (the default), a client_id that is an https URL with a path is fetched as a JSON document. The document must:

  • be a JSON object of at most 20,000 bytes, served with a 2xx within 3 seconds,
  • have client_id equal to its own URL,
  • have token_endpoint_auth_method none or no such field,
  • list valid redirect_uris.

Scute reads client_name, redirect_uris, client_uri and logo_uri from it. The document is fetched again when the stored copy is more than 24 hours old. If a refetch fails, the stored copy keeps working for up to 7 days after the last good fetch.

Manage clients from your backend#

These calls take the app key in Authorization: Bearer. A client object:

FieldTypeDescription
idstringUUID of the client. Used in the paths below.
client_idstringThe OAuth client id.
kindstringregistered, metadata_document or dynamic.
namestringDisplay name, or null.
redirect_urisarrayAllowed redirect URIs.
client_uri, logo_uristringhttps URLs, or null.
agent_idstringThe agent the client acts as, or null.
disabledbooleantrue when the client is disabled.
created_at, last_used_atstringISO 8601 times.

List clients#

GET/v1/apps/:app_id/oauth/clientsApp key

Newest first, up to 200. kind filters by kind. Returns { "clients": [ ... ] }.

Create a client#

POST/v1/apps/:app_id/oauth/clientsApp key
redirect_urisstring[]required
1 to 20 redirect URIs.
namestring
Up to 100 characters.
client_uristring
An https URL.
logo_uristring
An https URL.
cURLbash
curl -X POST https://api.scute.io/v1/apps/$SCUTE_APP_ID/oauth/clients \  -H "Authorization: Bearer $SCUTE_APP_KEY" \  -H "Content-Type: application/json" \  -d '{"name": "Internal agent", "redirect_uris": ["https://agent.acme.example/callback"]}'

Returns 201 with the client object. Validation failures return 422 with error_code invalid.

Update a client#

PATCH/v1/apps/:app_id/oauth/clients/:idApp key
namestring
Registered clients only.
redirect_urisstring[]
Registered clients only.
agentstring
Slug of the agent the client acts as. Empty clears it.
disabledboolean
true disables the client and revokes its active grants.

Changing name or redirect_uris of a dynamic or metadata_document client returns 422 with error_code invalid. An unknown agent slug returns 422 as well.

Delete a client#

DELETE/v1/apps/:app_id/oauth/clients/:idApp key

Returns 204. An unknown id returns 404 with error_code not_found.