API Reference

The PocketPaw web dashboard exposes a comprehensive REST API for managing channels, sessions, MCP servers, memory, security, and more. All endpoints are served by the FastAPI backend.

Base URL

http://localhost:8000

Endpoint Groups

Authentication

Most API endpoints require authentication. PocketPaw supports multiple auth methods:

Terminal window
curl http://localhost:8000/api/sessions \
-H "Authorization: Bearer your-access-token"
Terminal window
curl "http://localhost:8000/api/sessions?token=your-access-token"

Requests from 127.0.0.1 or ::1 bypass auth automatically (unless a Cloudflare tunnel is active).

Info

Auth-exempt paths: /webhook/*, /oauth/callback, /api/qr, /static/*, /favicon.ico

Quick Reference

Channels

MethodEndpointDescription
GET/api/channels/statusGet all channel statuses
POST/api/channels/saveSave channel configuration
POST/api/channels/toggleStart or stop a channel

Sessions

MethodEndpointDescription
GET/api/sessionsList all sessions
GET/api/sessions/searchSearch sessions
DELETE/api/sessions/{id}Delete a session
POST/api/sessions/{id}/titleRename a session
GET/api/memory/sessionGet session messages

MCP Servers

MethodEndpointDescription
GET/api/mcp/statusGet MCP server statuses
POST/api/mcp/addAdd an MCP server
POST/api/mcp/removeRemove an MCP server
POST/api/mcp/toggleEnable/disable MCP server
POST/api/mcp/testTest server connection
GET/api/mcp/presetsList available presets
POST/api/mcp/presets/installInstall a preset

Memory

MethodEndpointDescription
GET/api/memory/long_termList long-term memories
DELETE/api/memory/long_term/{id}Delete a memory entry
GET/api/memory/settingsGet memory config
POST/api/memory/settingsUpdate memory config
GET/api/memory/statsGet memory statistics

Security & Audit

MethodEndpointDescription
GET/api/auditGet audit log entries
POST/api/security-auditRun security audit
GET/api/self-audit/reportsList audit reports
GET/api/self-audit/reports/{date}Get specific report
POST/api/self-audit/runTrigger self-audit

Authentication & OAuth

MethodEndpointDescription
POST/api/auth/sessionGet session token
GET/api/qrGenerate QR login code
POST/api/token/regenerateRegenerate access token
GET/api/oauth/authorizeStart OAuth flow

Webhooks

MethodEndpointDescription
GET/api/webhooksList webhook slots
POST/api/webhooks/addCreate webhook slot
POST/api/webhooks/removeRemove webhook slot
POST/webhook/inbound/{name}Receive webhook payload

Tunnel

MethodEndpointDescription
GET/api/remote/statusGet tunnel status
POST/api/remote/startStart Cloudflare tunnel
POST/api/remote/stopStop tunnel