Skip to main content

Remote API Reference

DotAgents exposes a Fastify HTTP API for the mobile app, operator dashboards, local automation, and OpenAI-compatible clients. The server is disabled by default; enable it in Settings > Remote Server.


Base URL and Auth

Local default:

http://127.0.0.1:3210

Every protected endpoint expects:

Authorization: Bearer <remote-server-api-key>

Use 127.0.0.1 for local clients. Use a LAN IP, hostname, or Cloudflare Tunnel URL only when you intentionally expose the server.

OpenAI-Compatible Chat

POST /v1/chat/completions

Runs an agent through an OpenAI-compatible chat completions shape. Supports streaming and non-streaming responses.

{
"model": "agent:general-assistant",
"messages": [
{"role": "user", "content": "Search recent AI news and summarize the important bits."}
],
"stream": true
}

Notes:

  • Use the desktop-configured model or an agent/model alias exposed by /v1/models.
  • Tool use, MCP calls, skills, knowledge notes, and loop context are handled by the desktop runtime.
  • Streaming responses use server-sent events compatible with OpenAI-style clients.

GET /v1/models

Lists model and agent aliases that the remote client can use.

GET /v1/models/:providerId

Lists known models for one provider profile when the desktop runtime can resolve them.

Agent and Content Management

EndpointPurpose
GET /v1/agent-profilesList configured agent profiles.
GET /v1/agent-profiles/:idFetch one agent profile.
POST /v1/agent-profilesCreate an agent profile.
PATCH /v1/agent-profiles/:idUpdate an agent profile.
DELETE /v1/agent-profiles/:idDelete an agent profile.
POST /v1/agent-profiles/:id/toggleEnable or disable an agent profile.
GET /v1/skillsList skills available to agents.
POST /v1/skills/:id/toggle-profileEnable or disable a skill for a profile.
GET /v1/knowledge/notesList knowledge notes.
GET /v1/knowledge/notes/:idFetch one knowledge note.
POST /v1/knowledge/notesCreate a knowledge note.
PATCH /v1/knowledge/notes/:idUpdate a knowledge note.
DELETE /v1/knowledge/notes/:idDelete a knowledge note.
GET /v1/loopsList scheduled/autonomous loops.
POST /v1/loopsCreate a loop.
PATCH /v1/loops/:idUpdate a loop.
DELETE /v1/loops/:idDelete a loop.
POST /v1/loops/:id/toggleEnable or disable a loop.
POST /v1/loops/:id/runRun a loop immediately.

Conversations and Push

EndpointPurpose
GET /v1/conversationsList conversations.
POST /v1/conversationsCreate a conversation.
GET /v1/conversations/:idFetch a conversation and messages.
PUT /v1/conversations/:idUpdate conversation metadata/messages.
GET /v1/conversations/:id/assets/videos/:fileNameStream a video attachment that belongs to a conversation.
POST /v1/emergency-stopStop the active remote run.
POST /v1/push/registerRegister a push notification token.
POST /v1/push/unregisterRemove a push notification token.
GET /v1/push/statusRead push notification status.
POST /v1/push/clear-badgeClear the mobile badge count.

Speech and Media

EndpointPurpose
POST /v1/tts/speakGenerate speech audio with the desktop-configured TTS provider.
GET /v1/conversations/:id/assets/videos/:fileNameStream conversation-local video assets for mobile clients.

MCP and Settings

EndpointPurpose
GET /v1/mcp/serversList configured MCP servers and connection status.
POST /v1/mcp/servers/:name/toggleEnable or disable an MCP server.
GET /v1/settingsRead non-secret app settings for remote clients.
PATCH /v1/settingsUpdate remote-safe settings.
GET /v1/profilesList provider/model profiles for mobile settings.
GET /v1/profiles/currentRead the active provider/model profile.
POST /v1/profiles/currentSwitch the active provider/model profile.
GET /v1/profiles/:id/exportExport a provider/model profile.
POST /v1/profiles/importImport a provider/model profile.

ACP-Injected MCP Transport

These endpoints are active runtime endpoints used by ACP/acpx delegation and injected runtime tools. They are not the normal user-facing MCP configuration API above.

EndpointPurpose
POST /mcp/:acpSessionTokenInitialize or send a Streamable HTTP MCP request scoped to an ACP session token.
GET /mcp/:acpSessionTokenOpen the Streamable HTTP server-to-client stream for an ACP session token.
DELETE /mcp/:acpSessionTokenClose the injected MCP transport for an ACP session token.
POST /mcp/tools/listList injected runtime tools for the current request context.
POST /mcp/:acpSessionToken/tools/listList injected runtime tools scoped to an ACP session token.
POST /mcp/tools/callCall an injected runtime tool in the current request context.
POST /mcp/:acpSessionToken/tools/callCall an injected runtime tool scoped to an ACP session token.

Operator Endpoints

Operator endpoints are intended for trusted dashboards and automations.

EndpointPurpose
GET /v1/operator/statusOperator status summary.
GET /v1/operator/healthHealth and build/runtime metadata.
GET /v1/operator/errorsRecent error events.
GET /v1/operator/logsRecent operator log events.
GET /v1/operator/auditAudit events.
GET /v1/operator/conversationsOperator conversation list.
GET /v1/operator/remote-serverRemote server status/config snapshot.
GET /v1/operator/tunnelCloudflare Tunnel status.
GET /v1/operator/tunnel/setupTunnel setup instructions/status.
POST /v1/operator/tunnel/startStart tunnel exposure.
POST /v1/operator/tunnel/stopStop tunnel exposure.
GET /v1/operator/integrationsIntegration status summary.
GET /v1/operator/whatsappWhatsApp MCP/operator status.
POST /v1/operator/whatsapp/connectConnect/start WhatsApp integration.
POST /v1/operator/whatsapp/logoutLog out WhatsApp integration.
GET /v1/operator/discordDiscord integration status.
GET /v1/operator/discord/logsDiscord logs.
POST /v1/operator/discord/connectConnect Discord integration.
POST /v1/operator/discord/disconnectDisconnect Discord integration.
POST /v1/operator/discord/logs/clearClear Discord logs.
GET /v1/operator/updaterUpdater status.
POST /v1/operator/updater/checkTrigger update check.
POST /v1/operator/updater/download-latestDownload the latest update artifact.
POST /v1/operator/updater/reveal-downloadReveal the downloaded update in Finder/Explorer.
POST /v1/operator/updater/open-downloadOpen the downloaded update.
POST /v1/operator/updater/open-releasesOpen the GitHub releases page.
GET /v1/operator/mcpOperator MCP status.
POST /v1/operator/actions/mcp-restartRestart MCP services.
POST /v1/operator/actions/restart-remote-serverRestart the remote server.
POST /v1/operator/actions/restart-appRestart the desktop app.
POST /v1/operator/actions/run-agentRun an agent from the operator surface.
POST /v1/operator/access/rotate-api-keyRotate the remote API key.

Pairing Mobile

  1. Enable Settings > Remote Server in desktop.
  2. Show the QR code in desktop remote server settings.
  3. In mobile, open Connection Settings and scan it.
  4. Mobile stores the base URL and bearer token in device storage.

See Remote Server & Mobile Pairing for setup and security guidance.

Compatibility Notes

  • Legacy endpoints like /chat, /conversations, and /mcp/execute are no longer the documented surface. Use /v1/* endpoints.
  • The /mcp/:acpSessionToken endpoints above are current internal ACP/acpx runtime transport endpoints, not legacy /mcp/execute endpoints.
  • The API is local-first. Do not expose it without an API key, CORS review, and tunnel/firewall controls.
  • Provider model catalogs change frequently; use /v1/models or provider APIs for exact availability.

Next Steps