On This Page

API Reference: MCP

The MCP server lets AI assistants interact with ProcessMind through the Model Context Protocol. It speaks JSON-RPC 2.0 over Streamable HTTP: send initialize, then tools/list to discover the tool catalogue. Read tools such as list_processes are only listed when the API key has the read scope; write tools require the write scope. Use tools/call to invoke a tool with its arguments. Cross-session facts can be stored with the memory tools (remember, recall, forget), and long-running AI generations are tracked per tool call: attach a task reference in _meta["io.modelcontextprotocol/related-task"] and ProcessMind reports that task’s status with the call. The tasks/list, tasks/get and tasks/cancel extension methods are not served.

Model Context Protocol server endpoint (JSON-RPC over Streamable HTTP)

JSON-RPC 2.0 over Streamable HTTP: initialize, tools/list, tools/call, resources/list, resources/read, prompts/list. Read tools require the key’s read scope, write tools the write scope. The tool catalogue is documented in the MCP guide. Authenticate with x-api-key or Authorization: Bearer <token> (token from the OAuth token endpoint).

Endpoint: POST /v1/mcp/{tenantId}

Auth: Tenant-scoped API key · read scope · rate limit 20 req/s (burst 40)

Parameters:

Name Type Location Required Description
tenantId string path Yes Format: uuid

Request Body:

MCP JSON-RPC request

{}

Response (200):

MCP JSON-RPC response

{
	"message": "string"
}
Field Type Required Description
message string Yes

Errors:

  • 401 Missing, invalid, disabled or expired API key
  • 403 API key lacks the required scope or organization access, the tenant is inactive, or the plan blocks the file type

OAuth 2.1 authorization endpoint (PKCE), 302-redirects back to redirect_uri with ?code=…

Endpoint: GET /v1/mcp/{tenantId}/oauth/authorize

Auth: Public, no API key · rate limit 10 req/s (burst 20)

Parameters:

Name Type Location Required Description
tenantId string path Yes Format: uuid
client_id string query Yes
redirect_uri string query Yes Format: uri
code_challenge string query Yes
code_challenge_method S256 query No Allowed values: S256
state string query No

Errors:

  • 302 Redirect to redirect_uri with code + state
  • 400 Bad request: e.g. an invalid filter expression, a process without a model, an unsupported upload type or a missing required field
  • 401 Missing, invalid, disabled or expired API key

OAuth 2.0 token endpoint (client_credentials or authorization_code + PKCE)

Endpoint: POST /v1/mcp/{tenantId}/oauth/token

Auth: Public, no API key · rate limit 5 req/s (burst 10)

Parameters:

Name Type Location Required Description
tenantId string path Yes Format: uuid

Response (200):

Access token

{
	"access_token": "string",
	"token_type": "Bearer",
	"expires_in": 0
}
Field Type Required Description
access_token string Yes Short-lived Bearer JWT for POST /v1/mcp/{tenantId}
token_type Bearer Yes Allowed values: Bearer
expires_in number Yes

Errors:

  • 400 Bad request: e.g. an invalid filter expression, a process without a model, an unsupported upload type or a missing required field
  • 401 Missing, invalid, disabled or expired API key
  • 403 API key lacks the required scope or organization access, the tenant is inactive, or the plan blocks the file type