Docs

Connect AI assistants (MCP): Claude, ChatGPT, Cursor and VS Code

Add https://api.sovaria.in/mcp to your AI assistant and sign in: it works on the organization and project you pick, with your role, read-only or read and write, and asks before it changes anything.

Updated Nov 25, 2026

Sovaria runs a hosted MCP server (Model Context Protocol) at https://api.sovaria.in/mcp. Add it to Claude, ChatGPT, Cursor, VS Code or any MCP client and the assistant can read your schema, query data, change tables, deploy functions, check access rules and read logs — the same 240 tools Sovariq uses. There is nothing to install and no key to paste: the assistant signs you in with OAuth, and you choose in the Sovaria console what it may touch.

sign intokentool callpinned tokenYour assistantClaude, ChatGPT,Cursor…Sovaria consolepick org, project,accessapi.sovaria.in/mcphosted MCP serverYour projectyour role,policies, RLS

#Connect

The quickest way: in the console, open Sovariq › Settings › Integrations › Use Sovaria from Claude or ChatGPT and click the button for your app. Cursor and VS Code install it in one step; Claude opens its add-connector form already filled in; ChatGPT opens its connector settings with the URL copied (developer mode › Create); for Claude Code it copies the command. The AI itself runs on your own Claude or ChatGPT plan, not on your Sovariq credits. To set it up by hand:

Claude (web, desktop): Settings › Connectors › Add custom connector
Name: Sovaria
URL:  https://api.sovaria.in/mcp
Then press Connect and sign in to Sovaria.
Use the URL as is, or add options from the table below.

Sovariq › Settings › Use Sovaria in other AI apps shows the same snippets with your project filled in.

#Approve the connection

The first time, the assistant opens Sovaria in your browser. Sign in if you need to, then choose:

  • Organization: one of yours. The assistant can never see or act on another one.
  • Project: one project (the default), or Every project in the organization; then add ?project=<project id> to the URL to pick one per assistant setup.
  • Access: Read and write (the assistant asks you before anything that writes, deletes or runs code) or Read only (it only gets tools that read, and the API refuses changes).

Whatever you choose, an assistant never reaches your account's sign-in and security settings, billing, organization administration, API key values or Sovariq, and it can't register or re-point a webhook, an auth hook, a log drain or the project's email (SMTP) server, make a function public (its access switch, or verify_jwt: false on a deploy or update) or link the project to GitHub: those open a standing path for project data to leave, so do them in the console or with the CLI. Switching them off stays available. Schedules and flows that call a URL are not blocked: review what your assistant asks to run. Tools that send anything outside the project are marked destructive and open-world for your assistant, so one set to auto-approve "safe" tools still asks you first.

The page shows the app's name and where it returns (claude.ai, chatgpt.com, an app on your computer). An app registers itself, so it can pick any name: approve only if you just started connecting it and the return address looks right. When an app calls itself Claude, ChatGPT, Cursor or VS Code but doesn't return to that app's own address, the page says it may be pretending and asks you to confirm before Allow works. You get an email when an assistant is connected, and it appears in Account › Security › AI assistants and in your security activity.

#URL options

OptionExampleWhat it does
project?project=5f2c…The project to work on, for a connection you allowed on every project. It must be in the connected organization and open to you; a connection approved for one project always uses that one.
read_only?read_only=trueOnly read tools, whatever the connection allows. Asked for before you connect, it is also preselected (and locked) on the approval page.
features?features=database,storageLoad fewer tools. Categories: database, vectors, documents, storage, auth, policies, functions, simulation, versions, environments, realtime, observability, settings, api, billing, mobile, messaging, builds (context is always there).
mode?mode=codeMCP code mode: three tools (get_context, search_api, execute) instead of the full catalog. See below.

#MCP code mode: the whole API in two tools

The full tool list is about 65,000 tokens of tool definitions that your assistant reads on every request. With ?mode=code it gets three small tools (about 1,000 tokens, measured with hosted/scripts/measure_tool_tokens.py):

  • `search_api` finds operations in Sovaria's public OpenAPI by what you want to do, and shows one in full (parameters, body, responses, an example).
  • `execute` runs a short JavaScript function that calls those operations with sovaria.get(path, {query}), sovaria.post(path, body), … and returns only what it needs. Independent calls run together with Promise.all; a multi-step job is one tool call, and its intermediate results never fill your assistant's context.

The code runs in Sovaria's sandbox with no network, no files, no credentials and no data. Each API call it asks for comes back to the MCP server, is checked against the public API (only documented operations), and is made through the API with your connection's own token — the same checks as every tool call. Calls that change data need allow_writes: true (your assistant shows it when it asks you) and a read-and-write connection. Limits: 50 API calls per execute, answers up to 128 KB each, 10 seconds of compute per round; staff can change them in Control Center › Platform › Limits › AI assistants (MCP).

const [orders, me] = await Promise.all([
  sovaria.get('/rest/v1/orders', { query: { select: 'id,total,status', status: 'eq.paid', limit: '500' } }),
  sovaria.get('/api/v1/auth/me'),
]);
return { who: me.email, paid: orders.length, revenue: orders.reduce((s, o) => s + o.total, 0) };
What an assistant sends to execute.

#Protocol versions, tasks and tracing

  • MCP 2026-07-28 (stateless: server/discover, the version in each request's _meta, resultType on every result, Mcp-Method / Mcp-Name headers that must match the body) and 2025-06-18 (the initialize handshake) both work; your client picks.
  • Tool lists carry ttlMs: 300000 and cacheScope: private (they depend on your connection, so they are never shared) and come in a fixed order.
  • Tasks (io.modelcontextprotocol/tasks): when your client supports them, start_workflow answers a task whose id is the workflow's run id. tasks/get follows it, tasks/update answers a signal the workflow waits for, tasks/cancel stops it.
  • Tracing: a traceparent (and tracestate) in a request's _meta is passed on to every API call made for it, so the request traces in Observability join your client's trace.
  • The server is listed in the official MCP Registry as in.sovaria/sovaria, so assistants and catalogs that read the registry can find it. Sovaria proves it owns that name with the public key at https://sovaria.in/.well-known/mcp-registry-auth.

#What an assistant can do

Everything goes through Sovaria's API as you: your team role in the organization, access policies, row-level security, plan limits and the audit log apply exactly as in the console, and so does your organization's AI policy (Organization › Roles), which can narrow what any AI may do. On top of that, an assistant's token is held to the connection:

AllowedNever
WhereThe connected organization; the pinned projectOther organizations, other projects, listing your organizations
Read onlyReads, read-only SQL and GraphQL, searches, simulations, dry runsAnything that writes (MCP_READ_ONLY), and realtime sockets (they carry live row changes)
AccountYour name and email (who you are)Password, email, two-factor, passkeys, sessions, CLI or assistant connections, social and SSO links
MoneyReading plan, usage and spendChanging plans, subscriptions, spend caps or compute sizes
OrganizationSyncing connected integrationsMembers, invites, roles, the AI policy, SSO, encryption keys, creating or deleting organizations and projects

Calls outside these lines are refused with 403 and a code: MCP_SCOPE (another organization or project), MCP_READ_ONLY (a change on a read-only connection) or MCP_NOT_ALLOWED (account, money or organization administration). Tools that change something are marked as such in MCP, so your assistant asks before it runs them.

#See and disconnect assistants

  • Account › Security › AI assistants: each assistant with its organization, project, access and when it was last used. Disconnect ends it at once: its tokens stop working within seconds (the hosted MCP server may reuse a checked session for up to 30 seconds).
  • Organization settings › Security › AI assistants (owners and admins): members' connections, disconnect any, and turn connecting off for the organization — that ends every member's connection.
  • CLI: sov mcp connections, sov mcp disconnect <id>, sov mcp org --deny / --allow.
  • SDKs: sov.api.mcp.listConnections(), disconnect(id), orgSettings(), setOrgAllowed(false) (JavaScript); client.api.mcp.list_connections() (Python); Dart the same.

Losing access ends a connection too: removed from the organization or the project, or a deactivated account.

#For MCP client developers

The server follows the MCP authorization spec (OAuth 2.1). Clients that support remote MCP servers with OAuth need no Sovaria-specific code.

Value
MCP endpointhttps://api.sovaria.in/mcp (streamable HTTP, stateless, JSON responses)
Protected resource metadatahttps://api.sovaria.in/.well-known/oauth-protected-resource/mcp (also at the root path); a 401 names it in WWW-Authenticate with scope="mcp". A request without a token gets no error code (RFC 6750); an invalid, expired or revoked token gets error="invalid_token".
Browser clientsThe metadata, /oauth/register, /oauth/token, /oauth/revoke and /mcp answer CORS from any origin, without cookies (Access-Control-Allow-Origin: *), so web clients such as MCP Inspector can sign in. WWW-Authenticate is exposed to the page.
Authorization serverIssuer https://api.sovaria.in, metadata at /.well-known/oauth-authorization-server
Client registrationPreferred: a client ID metadata document (an https client_id serving its own JSON), as MCP 2026-07-28 recommends. Dynamic registration (POST /oauth/register, RFC 7591; public clients or client_secret_post/client_secret_basic) still works for older clients. grant_types must include authorization_code; other grant types a document lists (for example jwt-bearer or device_code) are ignored, and only authorization_code and refresh_token are used.
Issuer in responsesEvery authorization response (success or error) carries iss=https://api.sovaria.in (RFC 9207); check it before redeeming the code.
Redirect URIshttps; http://127.0.0.1, localhost or [::1] on any port; or an app's own scheme (cursor://…)
AuthorizationCode flow with PKCE S256 only; send resource=https://api.sovaria.in/mcp
Scopesmcp (what the member approves) or mcp:read (read only)
TokensOpaque access token (sov_mcp_…, 1 hour) and refresh token (sov_mcpr_…, 30 days, rotated on every use; reusing an old one ends the connection). Revoke with POST /oauth/revoke (RFC 7009)
curl -X POST https://api.sovaria.in/oauth/token \
  -d grant_type=authorization_code -d code="$CODE" \
  -d redirect_uri=http://127.0.0.1:53682/callback \
  -d client_id="$CLIENT_ID" -d code_verifier="$VERIFIER" \
  -d resource=https://api.sovaria.in/mcp
The token exchange after the member approves (public client).

Errors use OAuth's format ({"error": "invalid_grant", "error_description": "…"}); invalid_grant on refresh means the connection ended — start the authorization again.

#Run it locally instead

sov mcp serve runs the same tools over stdio with your CLI login and the project you selected with sov scope pick (or sov scope set); sov mcp config prints the entry for Claude Desktop, Claude Code or Cursor (named sovaria, like the hosted entry). Use it when your assistant only runs local (stdio) MCP servers (CLI: Logs, metrics, alerts, crashes, vectors and AI tools). If your CLI login is missing or has expired, the server still starts and answers every request with an error that says to run sov login; restart the server in your assistant after signing in.

#Troubleshooting

You seeWhyFix
The assistant asks you to sign in againThe connection ended (you or an admin disconnected it, the organization turned assistants off, or you lost access)Connect again
MCP_SCOPE … connected at organization levelThe connection allows every project, and the URL names noneAdd ?project=<project id> to the URL
MCP_READ_ONLYA read-only connection tried to change somethingDisconnect and connect again with Read and write
ORG_PERMISSION_REQUIRED or a Sovariq AI policy messageYour role, or the organization's AI policy, doesn't allow itAsk an owner or admin
"This organization doesn't allow connecting AI assistants"An owner or admin turned it offAsk them to allow it in Organization settings › Security

#Plans

Every plan, including Free. Calls count like any other API request toward your plan's rate limits and quotas.

#Coming from Firebase or Supabase?

PlatformWhat this is called there
FirebaseFirebase MCP server
SupabaseSupabase MCP server
SovariaConnect AI assistants (MCP): Claude, ChatGPT, Cursor and VS Code

Moving an existing app? Migrate from Supabase or Firebase imports users (with their passwords), data, files and rules.