Address

Reference

Apps

Apps such as ChatGPT and Claude connect by MCP and OAuth 2.1, and act as the person's agent.

Markdown

Calls go to https://address.seleya.ai/api. A refusal is {"error": {"code", "message"}} with its status; every code is in Errors.

Protected resource metadata

GET /.well-known/oauth-protected-resource

Called with .

RFC 9728, for the MCP server.

Answers

200
Done

Protected resource metadata (path form)

GET /.well-known/oauth-protected-resource/mcp

Called with .

The same metadata, at the path form RFC 9728 names for the MCP server.

Answers

200
Done

The MCP server

POST /mcp

Called with an app.

The MCP server, at https://address.seleya.ai/mcp. It speaks MCP 2026-07-28 and answers clients that start with initialize, over Streamable HTTP without sessions. Its tools are this API's calls, made as the app; MCP Events arrive by webhook.

Answers

200
Done
400
The request is malformed
401
No valid key, session or token
404
Not found, or not yours to see

Apps using an address

GET /v1/addresses/{a}/connections

Called with a key or a person signed in.

The apps using an address, for its holder or the company's admins.

Parameters

a string, in path required
Address name or UUID. Use the UUID for a nonexclusive pending request.

Answers

200
Done
401
No valid key, session or token
403
Not allowed for this caller
404
Not found, or not yours to see
Fields of the 200 answer
connections array of Connection
curl https://address.seleya.ai/api/v1/addresses/desk@acme.seleya.email/connections \
  -H "Authorization: Bearer $SELEYA_KEY"

Answer 200
{
  "connections": []
}

Give an app the use of this address, or ask for it

POST /v1/addresses/{a}/connections

Called with a key or a person signed in.

A person gives a connected app the use of this address (B2-O59). An app calls with no body to ask for an address its person holds (B2-O63). The call answers 202 with the signed-in review link. The person's approval gives the app the address.

Parameters

a string, in path required
Address name or UUID. Use the UUID for a nonexclusive pending request.

Body

connection string
The connection's id, from GET /v1/connections. A person sends it; an app asking for itself sends none.

Answers

202
The app's request is waiting for the person to review it
204
The app can use this address
401
No valid key, session or token
403
Not allowed for this caller
404
Not found, or not yours to see
Fields of the 202 answer
status awaiting_approval
awaiting_approval.
approval object
The ask: its id, kind and who decides.
curl -X POST https://address.seleya.ai/api/v1/addresses/desk@acme.seleya.email/connections \
  -H "Authorization: Bearer $SELEYA_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "connection": "00000000-0000-4000-8000-000000000000"
}'

Answer 202
{
  "status": "awaiting_approval",
  "approval": {
    "id": "7f3c9a2e-0000-4000-8000-000000000002",
    "kind": "use_address",
    "summary": "use desk@acme.seleya.email: read its mail and send from it",
    "waits_for": "a person",
    "review_url": "https://address.seleya.ai/#/approvals"
  }
}

Remove an app from an address

DELETE /v1/addresses/{a}/connections/{id}

Called by address.seleya.ai, signed in.

Stops an app using this address. A person only.

Parameters

a string, in path required
Address name or UUID. Use the UUID for a nonexclusive pending request.
id string, in path required
Its id.

Answers

204
Done, with no body
401
No valid key, session or token
403
Not allowed for this caller
404
Not found, or not yours to see

Apps acting for you

GET /v1/connections

Called by address.seleya.ai, signed in.

The apps acting for you, with their addresses and when each was last used.

Answers

200
Done
401
No valid key, session or token
Fields of the 200 answer
connections array of Connection
Answer 200
{
  "connections": [
    {
      "addresses": [
        "apps@seleya.me"
      ],
      "app": "Seleya Address test client",
      "client_id": "https://juiw7rjojt3cahaammkuzf3di40ycqbj.lambda-url.eu-central-1.on.aws/client/main.json",
      "id": "7f3c9a2e-0000-4000-8000-00000000001d",
      "last_used_at": "2026-10-22T00:40:34.644228+00:00",
      "returns_to": "127.0.0.1",
      "since": "2026-10-22T00:40:33.739498+00:00"
    }
  ]
}

Disconnect from the emailed link

POST /v1/connections/by-link

Called by address.seleya.ai, signed in.

Disconnects an app from the link in the new-connection email.

Body

token string required
The token from the emailed link's fragment.

Answers

200
Done
404
Not found, or not yours to see
Fields of the 200 answer
disconnected string

Disconnect an app

DELETE /v1/connections/{id}

Called by address.seleya.ai, signed in.

Disconnects an app at once. The off switch never depends on the app.

Parameters

id string, in path required
Its id.

Answers

204
Done, with no body
401
No valid key, session or token
404
Not found, or not yours to see

A2A protected resource metadata

GET /.well-known/oauth-protected-resource/a2a

Called with .

The OAuth resource https://address.seleya.ai/a2a uses Seleya Accounts. MCP tokens do not authorize this resource.

Answers

200
Done

Deliver a complete message through A2A

POST /a2a/{address}

Called with an app.

JSON-RPC binding of A2A 1.0.1, wire version 1.0. SendMessage, GetTask, ListTasks and CancelTask track mailbox acceptance. Streaming, push and extended-card methods are unsupported. IDs are scoped to issuer, subject, client and target. The outside peer needs verified email and OAuth consent; no paid local mailbox or recipient grant is required. Retry the same messageId after uncertain responses. Use returnImmediately true for asynchronous acquisition. The host replies by ordinary email.

Parameters

address string, in path required
Exact recipient mailbox, URL encoded.
A2A-Version 1.0, in header required

Body

jsonrpc 2.0 required
id string or number, or null required
method string required
params object

Answers

200
JSON-RPC result or protocol error
401
Authorization refused; WWW-Authenticate names the resource metadata
404
No A2A interface is published
503
Receipt still processing at the transport deadline; retry the same message ID
Fields of the 200 answer
jsonrpc 2.0
id string or number, or null
result object
error object
curl -X POST https://address.seleya.ai/api/a2a/ADDRESS

Docs