Skip to Content
Bryfo Docsv0.2.1
交互式 OpenAPI

MCP

Scoped bry_ Bearer token management and confirm_write human-approval queue for /mcp.

GET
/api/v1/mcp/tokens

Authorization

SessionCookie
cookiebryfo_session<token>

HttpOnly, SameSite=Lax session cookie (7-day sliding TTL, 30-day cap).

Response Body

Token metadata list

Example Request
curl -X GET 'https://mail.example.com/api/v1/mcp/tokens' \  --cookie 'bryfo_session='
Example Response200
Empty
POST
/api/v1/mcp/tokens

Authorization

SessionCookieStepUpToken
cookiebryfo_session<token>

HttpOnly, SameSite=Lax session cookie (7-day sliding TTL, 30-day cap).

headerX-Bryfo-Step-Up<token>

10-minute session-bound elevation token minted via POST /api/v1/auth/step-up.

Request Body

application/json
  1. body
name*string
scope*string
Value in"read_only""draft_only""confirm_write""full"
allowed_account_ids?array<>
apply_privacy_filter?boolean
Defaulttrue

Response Body

One-time plaintext bry_ token and metadata

Example Request
curl -X POST 'https://mail.example.com/api/v1/mcp/tokens' \  -H 'X-Bryfo-Step-Up: ' \  --cookie 'bryfo_session=' \  -H 'Content-Type: application/json' \  -d '{  "name": "string",  "scope": "read_only"}'
Example Response201
Empty
POST
/api/v1/mcp/pending/{id}/approve

Authorization

SessionCookie
cookiebryfo_session<token>

HttpOnly, SameSite=Lax session cookie (7-day sliding TTL, 30-day cap).

Path Parameters

id*string
Formatuuid

Response Body

Staged MCP action executed and audited

Example Request
curl -X POST 'https://mail.example.com/api/v1/mcp/pending/497f6eca-6276-4993-bfeb-53cbbbba6f08/approve' \  --cookie 'bryfo_session='
Example Response200
Empty