Skip to content
LogoLogo

Create a Workspace MCP service credential

Create a Workspace MCP service credential

POST/api/v1/workspaces/{workspace_id}/mcp-service-credentials

Creates a non-human service actor and a Workspace-bound MCP credential. The raw credential is returned exactly once. An empty project_ids array permits every currently visible Project in the Workspace; a non-empty array narrows the credential to those Projects.

Path Parameters

workspace_idRequired
string <uuid>
Example0198ac5e-f9b7-7000-8000-000000000001

Header Parameters

X-CSRF-TokenRequired
string·min 43·max 43

Session-bound CSRF token. It must exactly match the __Host-assign_csrf cookie sent with the request.

Request Body

application/json
nameRequired
string·min 1·max 100
scopesRequired
string[]·min 1·max 37
Values
assign:activity:readassign:agents:readassign:agents:writeassign:attachments:readassign:attachments:write
project_idsRequired
string <uuid>[]·max 100
expires_at
string <date-time>

Optional expiry no more than one year after creation; defaults to 90 days.

Responses