Skip to main content

API Reference

Nexus exposes a REST API via Supabase Edge Functions, the Supabase auto-generated PostgREST API, and a hosted MCP endpoint for AI agents. This section covers authentication, conventions, AI-agent access, the social/content-calendar MCP surface, and the public OpenAPI specification.

In this section

API base URLs

ServiceBase URLDescription
Edge Functionshttps://<project-ref>.supabase.co/functions/v1/Custom serverless endpoints
PostgRESThttps://<project-ref>.supabase.co/rest/v1/Auto-generated CRUD from database
Authhttps://<project-ref>.supabase.co/auth/v1/Supabase Auth endpoints
Storagehttps://<project-ref>.supabase.co/storage/v1/File uploads and downloads
MCPhttps://<project-ref>.supabase.co/functions/v1/mcp-serverHosted MCP Streamable HTTP endpoint

Replace <project-ref> with your Supabase project reference. Exact URLs are provided during onboarding and are not published publicly.

Security model

All API requests require a valid bearer token unless explicitly documented as public. Nexus uses three credential classes:

  1. User JWT — issued by Supabase Auth after login. Used by human users and admin tooling.
  2. Agent JWT — short-lived bearer token issued by agent-auth after exchanging an agent API key.
  3. Service Role Key — privileged server-to-server credential. Never exposed to clients or public documentation.

Agent API keys are not used directly against business endpoints. They are exchanged for agent JWTs first.

Every write endpoint is explicitly marked "Auth Required" in the specification. Read endpoints also require authentication unless explicitly marked as public (e.g., webhook receivers with verify-token validation).

Endpoint tags

The OpenAPI specification organizes endpoints into these tags:

TagDescription
AuthAuthentication and session management
ContactsContact (customer) CRUD and search
MessagesSend and receive messages across channels
OrdersOrder management and lifecycle
InventoryStock, warehouse, and bin operations
ShippingAWB creation, tracking, labels
VoIPCall initiation, CDR, extensions
AIAI annotation, insights, embeddings
AutomationWorkflow rules and execution
IntegrationsIntegration setup and sync
AgentsAPI-key exchange, MCP access, and agent integrations