Skip to main content

MCP Server

NearSync runs a hosted Model Context Protocol (MCP) server so an AI agent — Claude, ChatGPT, an MCP-capable IDE — can read your data in natural language ("how's my pipeline?", "what does my day look like?", "do I have the call with Acme today?").

It is read-only, org-isolated, and permission-aware: an agent only ever sees data the connecting user is allowed to see. There are two surfaces:

  • Org analytics — pipeline, revenue, MRR, etc. — gated by your role (a sales rep can't read finance metrics).
  • Personal — your tasks and schedule — scoped to you.

Endpoint

https://api.nearsync.tech/mcp

Streamable HTTP (JSON-RPC 2.0). Two ways to authenticate:

One click, no keys to copy. Most MCP clients let you add a remote server by URL and run the OAuth flow themselves (Dynamic Client Registration + PKCE — nothing to pre-register):

  1. In your client, add a custom/remote MCP connector with the URL https://api.nearsync.tech/mcp.
  2. The client opens a NearSync consent screen — sign in (or you're already signed in), confirm which account + org, and click Allow.
  3. Done. The agent now has the tools, scoped to your permissions.

The agent only sees:

  • the analytics your role permits (e.g. finance metrics only if you have Finance access), and
  • your own tasks and schedule.

Tokens are short-lived and refresh automatically; revoke a connection any time from your client.

Option B — Connect with an API key (developer / automation)

For scripts, automation, or clients without OAuth. Mint a key in System → API Keys (needs the analytics:read scope, and tasks:read/schedule:read for personal tools), then pass it as a bearer token. For clients that bridge stdio to a remote server (e.g. Claude Desktop):

{
"mcpServers": {
"nearsync": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://api.nearsync.tech/mcp",
"--header", "Authorization: Bearer ns_live_..."]
}
}
}
Keys vs OAuth

A key is a machine credential — it carries whatever scopes the admin granted and is not narrowed per-user (use it for automation an admin owns). OAuth is per-user and RBAC-narrowed — the agent sees only what that person is cleared for. Personal tools (my_tasks, etc.) require OAuth (a key has no user).

Tools

ToolArgsReturnsScope
list_metricscategory?The metrics/reports you can read (filtered to your permissions). Start here.analytics:read
run_metricmetric (name or id), period?, filters?One metric's result (number / series / table / computed). Denied if your role can't see its category.analytics:read
dashboard_insights"What changed" — metrics with material movement (stale-data drops flagged, not counted as declines).analytics:read
org_mrrMonthly recurring revenue (finance-gated).analytics:read
org_healthOrganization health score.analytics:read
my_tasksfilter? (open/overdue/today/upcoming/all)Your tasks.tasks:read
my_scheduledate? / range?Your meetings/calls.schedule:read
my_daydate?Your tasks + meetings for a day.tasks:read

Tools appear in tools/list only when your connection carries the scope. run_metric accepts a metric name (from list_metrics) or its UUID — the server resolves names. Money is in your organization's base currency.

Example

{ "jsonrpc": "2.0", "id": 1, "method": "tools/call",
"params": { "name": "my_day", "arguments": { "date": "2026-06-03" } } }

Limits & errors

401 — missing/invalid/expired credential (re-auth). 403 / tool isError — your role lacks the metric's category, or the tool needs a connected user (personal tools over a key). API keys count against a per-minute rate limit + monthly quota (see Rate Limits & Quota); quota is charged only on a call that reaches data.