RareMargin

Razão geral nativo em IA para empresas SaaS. Consulte demonstrativos, métricas SaaS, faturas, contas a pagar, lançamentos bancários não conciliados, controles e status do fechamento, e crie rascunhos de lançamentos contábeis e apropriações que aguardam aprovação humana. 17 ferramentas; servidor remoto com autenticação OAuth.

Servidor MCP hospedado

npx add-mcp 'https://raremargin.com/mcp'

Instala no Claude Code, Codex, Cursor e outros

Documentação

Use RareMargin in Claude, ChatGPT and Cursor

https://raremargin.com/docs/use-raremargin-in-claude-chatgpt-and-cursor · Updated 2026-11-18

RareMargin runs an MCP server at https://raremargin.com/mcp, so an AI assistant can read your books and draft entries for a person to approve. claude.ai, Claude Desktop, Claude Code and ChatGPT connect by signing in to RareMargin, where you choose the company and what the assistant may do. Cursor and OpenAI’s Codex connect with a RareMargin API key.

AssistantWorks todayHow it connects
claude.ai, web and mobileYesA custom connector with the URL, then sign in to RareMargin
Claude DesktopYesThe same custom connector, under Settings, Connectors
Claude CodeYesOne claude mcp add command, then sign in from /mcp; or an API key in a header
ChatGPTYesAn app added in developer mode, then sign in to RareMargin
CursorYesmcp.json, with an API key in a header
OpenAI CodexYesconfig.toml, with an API key in an environment variable

Can I use RareMargin from Claude?

Yes. On claude.ai and in Claude Desktop, add a custom connector under Settings, Connectors with the URL https://raremargin.com/mcp, then sign in to RareMargin when Claude asks. The connector then works in the Claude mobile apps too.

Leave the OAuth client ID and secret empty: Claude registers itself with RareMargin. Claude Code connects with one command (below).

Can I use RareMargin from ChatGPT?

Yes. Turn on developer mode in ChatGPT’s settings, add an app with the URL https://raremargin.com/mcp and OAuth sign-in, then sign in to RareMargin. OpenAI’s Codex connects with an API key read from an environment variable.

What happens when an assistant signs in to RareMargin?

RareMargin opens its own sign-in page, then asks which company the assistant may use and its role: Viewer only reads, and Accountant can also draft entries and accruals for approval. The assistant never sees your password.

It never gets more than your own role, and if your role drops or you leave the company, its access follows. It renews its access every hour while you use it. Every app you connect is listed in Settings, API & MCP, under Connected apps, where you or an admin can disconnect it at once.

What can an AI assistant do in RareMargin?

It gets the same 17 tools as RareMargin’s built-in assistant: 15 read the books, and 2 draft a journal entry or an accrual that waits for a person to approve it.

So it can answer questions like these from your own books:

  • What is our runway, and what changed in burn since last month?
  • Which customers owe us money, and which invoices are overdue?
  • Which bank lines are still unmatched, and what do they probably match?
  • Did any control fail, and what is the evidence?
  • Which recurring vendors haven’t billed this month? Draft accruals for them.
ToolWhat it does
get_company_overviewCash, burn, runway, MRR, AR and AP, close status and what needs attention
list_accountsThe chart of accounts
get_financial_reportAny report, from the trial balance to SaaS metrics
search_journal_entriesFind entries by memo, account, dates, status or source
list_customersCustomers and what they owe
list_open_invoicesInvoices not yet paid
list_vendorsVendors and what is owed to them
list_open_billsBills not yet paid
list_unmatched_bank_transactionsUnmatched bank lines, with ranked match suggestions and reasons
run_controlsThe 11 continuous controls and their evidence
detect_anomaliesDuplicates, outliers and risky manual entries
flux_analysisChanges by account against the prior period, with what drove them
close_statusThe close checklist and what is left
accrual_suggestionsRecurring vendors that haven’t billed this month
verify_ledgerChecks the SHA-256 hash chain over posted entries
propose_journal_entryDrafts a journal entry for a person to approve
propose_accrualDrafts an accrual, reversing next month, for approval

How do I get a RareMargin API key for an AI assistant?

Assistants that sign in don’t need one. For Cursor, Codex or a script, an admin creates a key in RareMargin under Settings, API & MCP, and picks its role: a Viewer key only reads, and an Accountant key can also write. Over MCP, as Cursor and Codex use it, an Accountant key’s entries and accruals always wait for approval.

The full key, which starts with ck_, is shown once, so store it in a password or secret manager. Name the key after the assistant, such as “Claude Code”. An Admin key has full access, which an assistant doesn’t need.

The REST API treats an Accountant key the same way: its journal entries and bills wait in the approvals inbox. Only an Admin key posts directly, and approval workflows with the source API can still hold its writes.

How do I connect Claude Code to RareMargin?

Run one command, then open /mcp in Claude Code, pick raremargin and sign in to RareMargin in the browser. Add --scope user to use it in every project.

claude mcp add --transport http raremargin https://raremargin.com/mcp

Or skip the sign-in with an API key in a header:

claude mcp add --transport http raremargin https://raremargin.com/mcp \
  --header "Authorization: Bearer $RAREMARGIN_API_KEY"

How do I connect Claude Desktop to RareMargin?

Add RareMargin as a custom connector under Settings, Connectors, Add custom connector, with the URL https://raremargin.com/mcp, and sign in to RareMargin. A connector added on claude.ai shows up in Claude Desktop as well.

How do I connect Cursor to RareMargin?

Add RareMargin to Cursor’s mcp.json, in ~/.cursor for every project or in a project’s .cursor folder, with the API key in a header.

{
  "mcpServers": {
    "raremargin": {
      "url": "https://raremargin.com/mcp",
      "headers": {
        "Authorization": "Bearer ${env:RAREMARGIN_API_KEY}"
      }
    }
  }
}

Cursor fills in ${env:RAREMARGIN_API_KEY} from your environment, so the key stays out of the file.

How do I connect OpenAI’s Codex to RareMargin?

Add RareMargin to ~/.codex/config.toml, and Codex sends the API key from an environment variable as a Bearer token.

[mcp_servers.raremargin]
url = "https://raremargin.com/mcp"
bearer_token_env_var = "RAREMARGIN_API_KEY"

Do Xero, QuickBooks Online and NetSuite have MCP servers for Claude?

Yes, all three have MCP servers now, mostly aimed at developers: Xero hosts a remote one that reads and writes, Intuit publishes a QuickBooks Online server you run on your own machine, and NetSuite has its AI Connector Service.

LedgerMCP serverWhat it can doHow it connects
XeroA remote server hosted by Xero, for apps on Xero’s Core developer plan or above; also an open-source server, XeroAPI/xero-mcp-serverReads and writes: 39 tools across invoicing, accounting, reporting and payments; Xero says its tools don’t ask the user to confirmOAuth 2.0 with PKCE, one organisation per call; the open-source server uses a custom connection
QuickBooks OnlineAn open-source server from Intuit that runs on your machine; a hosted server in an invitation-only pilotReads and writes: 145 tools with create, read, update and deleteOAuth 2.0 through your own Intuit developer app
NetSuiteThe NetSuite AI Connector Service, with the free MCP Standard Tools SuiteAppCreates and updates records, runs reports and saved searches; SuiteQL queries are read-onlyOAuth 2.0 with PKCE; administrator roles can’t use it
RareMarginA remote server in every plan, at /mcp17 tools: 15 read the books, and 2 draft a journal entry or an accrual as an approval request, never a postingSign in from Claude or ChatGPT; an API key for Cursor, Codex and others

Xero also offers a Claude connector for everyday use that can read your books but not change them, and Intuit offers QuickBooks inside Claude and ChatGPT. Each vendor’s facts here come from its own website or GitHub, read on 7 November 2026. The Xero vs QuickBooks Online comparison covers the rest of how the three products differ.

Is it safe to let an AI assistant into my books?

An assistant can do only what the role you gave it allows, and RareMargin’s two write tools create approval requests, never postings, so a person decides what reaches the ledger.

Assistants and API keys can’t approve anything. Every proposal made over MCP waits for a person, whatever approval rules the company has set, and records that it came over MCP and which app sent it. Disconnecting the app or revoking the key in Settings cuts the assistant off at once.

Sources: