Tring

v0.2.0
il.co.tring/tring-mcp Checked 1 day ago Published 8 days ago

Israeli receipts and invoices: read documents, prepare drafts, issue only after a person approves.

MCP server of the Tring API, for Claude Code, Cursor and any MCP client. An agent can read documents and customers and prepare drafts; issuing is a separate tool that refuses unless a person approved the exact draft. בעברית: שרת ה-MCP של טרינג לסוכני AI. הסוכן מכין טיוטה, ומפיקים רק אחרי שאדם אישר אותה.

Summary extracted from the README.

tring-mcp

MCP server of the Tring API, for Claude Code, Cursor and any MCP client. An agent can read documents and customers and prepare drafts; issuing is a separate tool that refuses unless a person approved the exact draft.

בעברית: שרת ה-MCP של טרינג לסוכני AI. הסוכן מכין טיוטה, ומפיקים רק אחרי שאדם אישר אותה. התיעוד: developers.tring.co.il/ai.html

Connect

Claude Code:

claude mcp add tring --env TRING_API_KEY=kbl_test_... --env TRING_ISSUER_ID=... -- npx -y tring-mcp

Cursor (.cursor/mcp.json):

{ "mcpServers": { "tring": { "command": "npx", "args": ["-y", "tring-mcp"], "env": { "TRING_API_KEY": "${env:TRING_API_KEY}" } } } }
Variable
TRING_API_KEY required; a sandbox key kbl_test_...
TRING_ISSUER_ID default business for the tools
TRING_FILES_DIR the only folder tring_attach_expense_receipt reads a file from by path (default: the folder the server was started in); links are resolved first, and a path outside it is refused; when it is the home folder or the root of the disk, nothing is read by path
TRING_BASE_URL default the sandbox
TRING_MCP_ALLOW_LIVE 1 allows a kbl_live_ key; without it such a key is refused and nothing is sent

Tools

tring_status, tring_list_events, tring_list_webhook_endpoints, tring_list_webhook_deliveries, tring_get_document_design, tring_list_businesses, tring_get_business, tring_list_documents, tring_get_document, tring_list_customers, tring_get_customer, tring_get_reference, tring_prepare_draft (issues nothing), tring_get_draft, tring_preview_draft, tring_attach_expense_receipt (the supplier's receipt of an expense, from a local JPEG, PNG or PDF inside TRING_FILES_DIR, or base64; keep it under "ask" in the permissions of the coding tool; anything else by its first bytes is refused before it is sent), tring_get_expense_receipt (writes it back to a private local file), and tring_confirm_draft (issues).

Safety

  • tring_confirm_draft says in its description that it creates a legally binding tax document and may run only after the person approved the exact draft shown. It takes the approved_total, approved_doc_type and the person's words, re-reads the draft, and refuses when they differ.
  • In Claude Code, keep it behind a question: "permissions": { "ask": ["mcp__tring__tring_confirm_draft"] }.
  • Confirming twice returns the same document; an unknown outcome tells the agent to confirm the same draft again, never to prepare a new one.
  • Keys are never written to tool results or to the log (stderr); previews go to a private per-process directory (0700, files 0600, created exclusively, never through a symlink).

MIT