GET Signed-in browser session
/api/v1/meGet your account
Read your account ID and display name.
Request: JavaScript
const response = await fetch("/api/v1/me", {
credentials: "include",
});Response: 200 OK
{
"id": "35106440-4840-4d89-aa0d-c6ec6f12b313",
"name": "Sam"
}Responses
200OKThe request succeeded.400InvalidThe request doesn’t match the expected input.401UnauthorizedSign in or supply a valid credential for this route.403ForbiddenThe credential lacks permission, or the request isn’t allowed.404Not foundThe resource doesn’t exist or isn’t available to you.409ConflictThe requested change conflicts with the current state or an account limit.413Too largeThe request body exceeds the size limit.429Rate limitedWait before sending more requests.503UnavailablePoll Express couldn’t complete the request right now.
Response schema: application/json
| Field | Type |
|---|---|
idRequired | string |
nameRequired | string |
JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|[fF]{8}-[fF]{4}-[fF]{4}-[fF]{4}-[fF]{12})$",
"format": "uuid"
},
"name": {
"type": "string"
}
},
"required": [
"id",
"name"
],
"additionalProperties": false
}POST One-time setup token
/api/v1/agent-setup/exchangeExchange an agent setup token
Send the one-time setup token as a bearer credential. A successful exchange consumes it and shows the new MCP key once.
Request: curl
curl -sS -X POST "https://poll.express/api/v1/agent-setup/exchange" \
-H "Authorization: Bearer $POLL_SETUP_TOKEN" \
-H "Content-Type: application/json" \
--data '{"agentName":"Workshop assistant"}'Response: 201 Created
See the response schema below.
Request body: application/json
| Field | Type |
|---|---|
agentNameRequired | string |
JSON Schema
{
"type": "object",
"properties": {
"agentName": {
"type": "string"
}
},
"required": [
"agentName"
],
"additionalProperties": false
}Responses
201CreatedThe request created a resource.400InvalidThe request doesn’t match the expected input.401UnauthorizedSign in or supply a valid credential for this route.403ForbiddenThe credential lacks permission, or the request isn’t allowed.404Not foundThe resource doesn’t exist or isn’t available to you.409ConflictThe requested change conflicts with the current state or an account limit.413Too largeThe request body exceeds the size limit.429Rate limitedWait before sending more requests.503UnavailablePoll Express couldn’t complete the request right now.
Response schema: application/json
| Field | Type |
|---|---|
idRequired | string |
keyRequired | string |
scopesRequired | "poll.read" | "poll.write" | "poll.live"[] |
expiresAtRequired | string |
JSON Schema
{
"type": "object",
"properties": {
"id": {
"type": "string"
},
"key": {
"type": "string"
},
"scopes": {
"type": "array",
"items": {
"type": "string",
"enum": [
"poll.read",
"poll.write",
"poll.live"
]
},
"uniqueItems": true
},
"expiresAt": {
"type": "string"
}
},
"required": [
"id",
"key",
"scopes",
"expiresAt"
],
"additionalProperties": false
}