MCP server

Run your books from chat.

CompanyStack exposes your accounting workspace over the Model Context Protocol, so an assistant can record transactions, raise invoices, and read financial statements the same way the dashboard does — 98 tools over one authenticated endpoint.

Server URL

https://staging.api.companystack.io/mcp
Transport
Streamable HTTP
Auth
OAuth 2.1, browser approval
Scope
Your organizations only

Connecting

  1. Step 1

    Create your workspace

    Sign up on CompanyStack, create an organization, and finish the basic accounting setup. The MCP server operates an existing workspace — it cannot create one for you.

  2. Step 2

    Add the server to your client

    Point Claude, ChatGPT, or any MCP-capable client at the endpoint below. The server speaks streamable HTTP.

  3. Step 3

    Authorize in the browser

    The server is OAuth-protected. Your client opens a browser approval flow; once you approve, the connection is scoped to your account's organizations.

How the server behaves

The server ships these rules as MCP instructions, so a connected client follows them without being prompted.

Organizations are explicit
Start with list_organizations, then pass organizationId on every organization-scoped call. There is no server-side active organization.
Drafts by default
New transactions and journal entries are created as drafts. Posting, voiding, settling, and deleting are final or destructive, and clients are instructed to confirm before running them.
Dates and currency
Dates are YYYY-MM-DD. Foreign-currency lines need an exchange rate — look one up with get_exchange_rate and pass it explicitly. A missing rate is an error.
Check before you create
Use list_accounts before creating accounts so the assistant does not duplicate an existing ledger account.
Read the playbook first
The bookkeeping playbook resource explains how to book common transactions in double entry. Clients are told to read it before posting anything unusual.

Tools

98 tools across 9 areas. Tools markedwriteschange your books; the rest only read.

Organization

Workspace identity, members, and the company details printed on documents.

  • list_organizations

    Organizations the signed-in user belongs to, with role and organization type. Always the first call.

  • get_organization

    Organization details including baseCurrency — the reporting currency used for FX conversion.

  • update_organizationwrites

    Update name, address, email intake, and company details. Owner or admin.

  • list_organization_members

    Members of the organization with roles.

  • update_company_detailswrites

    Invoice letterhead and bank details shown on generated documents.

  • normalize_address

    Google Maps address normalization for company details.

  • get_dashboard_overview

    Headline workspace numbers for a week or month period.

  • get_subscription_summary

    Current subscription and billing summary.

  • list_subscription_invoices

    Stripe subscription invoices for the organization.

  • list_currencies

    Every currency supported for accounts, invoices, and transactions.

  • get_exchange_rate

    Latest stored rate from one currency to another on or before a date.

Chart of accounts

The ledger's accounts, their balances, and party tax identifiers.

  • list_accounts

    Paginated chart of accounts with computed balances.

  • create_accountwrites

    Create a chart-of-accounts entry. Field requirements depend on account type.

  • create_accountswrites

    Create 1–1000 accounts in one call.

  • get_account

    Fetch a single account.

  • update_accountwrites

    Update an account. Contact fields are valid only on party accounts, which must retain a full address.

  • delete_accountwrites

    Delete an account. Fails if it already has posted journal lines.

  • archive_accountwrites

    Archive an account.

  • unarchive_accountwrites

    Restore an archived account.

  • list_account_tax_identifiers

    Tax identifiers on a party account (sundry debtor or creditor).

  • create_account_tax_identifierwrites

    Add a party tax identifier. GSTIN requires an Indian contact country and passes local validation.

  • update_account_tax_identifierwrites

    Update a party tax identifier.

  • delete_account_tax_identifierwrites

    Remove a party tax identifier.

  • validate_account_tax_identifierwrites

    Verify a party VAT number with EU VIES and store the check with its consultation number.

Journal entries

Double-entry postings. Entries are created as drafts and posted explicitly.

  • list_journal_entries

    Paginated journal entries with lines and attachment metadata.

  • create_journal_entrywrites

    Create a draft manual journal.

  • get_journal_entry

    Fetch a single journal entry.

  • update_journal_entrywrites

    Update a draft entry only.

  • delete_journal_entrywrites

    Delete a draft entry only.

  • create_journal_entries_bulkwrites

    Create 1–1000 draft entries.

  • post_journal_entries_bulkwrites

    Post 1–300 draft entries at once.

  • post_journal_entrywrites

    Move an entry from draft to posted.

  • void_journal_entrywrites

    Move a posted entry to void.

  • link_journal_attachmentwrites

    Copy an attachment from another entry in the same organization.

Transactions

Shorthand tools that write a correctly balanced, posted journal entry.

  • record_incomewrites

    Post an income entry.

  • record_expensewrites

    Post an expense entry.

  • record_transferwrites

    Post a transfer between accounts.

  • record_bulk_incomewrites

    Post up to 1000 income entries.

  • record_bulk_expenseswrites

    Post up to 1000 expense entries.

  • record_bulk_transferwrites

    Post up to 1000 transfers.

  • record_paymentwrites

    Post a payment or receipt, optionally linked to an invoice.

  • get_account_transactions

    Drill down into posted transactions for one account over a date range.

  • import_bank_statementwrites

    Create bank-statement journal entries from parsed transactions.

Invoices

Sales and purchase invoices, their tax computation, and payment matching.

  • list_invoices

    Invoices with party details.

  • create_invoicewrites

    Create a sales or purchase invoice with tax computation.

  • create_invoiceswrites

    Create 1–100 invoices in one call.

  • update_invoice_draftwrites

    Edit a draft invoice. Omitted fields keep their value; lines replace all lines and tax is determined again.

  • issue_invoicewrites

    Move a draft invoice to issued: assigns the next gapless number from its series and posts the journal. Cannot be undone, only voided or credited.

  • get_invoice

    Fetch a single invoice.

  • get_invoice_payment_summary

    Amounts paid and outstanding.

  • list_invoice_potential_payments

    Unmatched journal entries touching this invoice's customer or vendor account.

  • post_invoicewrites

    Create and post the invoice's journal entries.

  • void_invoicewrites

    Void the invoice and its linked entries.

  • settle_invoicewrites

    Settle an invoice against journal entries.

  • resolve_invoice_overpaymentwrites

    Resolve an overpaid invoice.

  • record_invoice_receiptwrites

    Record a customer payment against a sales invoice, with an exchange rate when the currency differs from base.

  • record_invoice_paymentwrites

    Record a vendor payment against a purchase invoice, with an exchange rate when the currency differs from base.

  • delete_invoice_draftwrites

    Delete a draft invoice, only while every linked entry is still a draft.

  • record_invoice_e_invoicewrites

    India: record the IRN, acknowledgement, and signed QR code the IRP returned for an issued sales invoice.

  • create_credit_notewrites

    Issue a credit note against an issued sales invoice, in full or per line, mirroring the original's tax.

  • apply_credit_notewrites

    Apply a credit note's unapplied balance to another open sales invoice of the same customer and currency.

  • refund_credit_notewrites

    Refund a credit note's unapplied balance to the customer from a bank or cash account.

  • list_invoice_number_series

    Number series with the number each would assign next.

  • create_invoice_number_serieswrites

    Add a number series. One series per scope is the default used when issuing.

  • get_invoice_number_series

    Fetch a single number series.

Reports

Financial statements computed from posted entries, plus the month-end FX revaluation.

  • get_profit_loss

    Income versus expense accounts for a date range.

  • get_trial_balance

    Posted-journal trial balance.

  • get_balance_sheet

    Assets, liabilities, and equity as of a date. Same account-type layout in every market.

  • list_outstanding_bills

    For books that come from Tally: open payables or receivables per party and bill, with payments against each bill and ageing.

  • list_dimensions

    The dimensions amounts are tagged with across accounts, such as jobs, projects or cost centres, with how many values each has.

  • get_dimension_report

    Income, expense and net per dimension value, such as job-wise profit. For one value: the accounts behind it and its invoices.

  • list_custom_fields

    Fields kept on accounts, journals and invoices beyond the built-in ones. Journals and invoices can be filtered by them.

  • query_books

    One read-only SQL statement over this organization's books, for questions the other reports cannot answer in a call or two. Job numbers are the Job No dimension. The financial year starts 1 April.

  • run_fx_revaluationwrites

    Revalue foreign-currency balances at the month's closing rate, posting an unrealized FX journal and its reversal. Re-running a month replaces both.

  • get_sales_by_jurisdiction

    Sales mix for the current financial year, grouped by customer destination country or state.

Tax

Organization tax registrations, tax preview, and India-specific helpers.

  • list_tax_registrations

    Organization-level registrations — GSTIN, VAT, EIN, and others.

  • create_tax_registrationwrites

    Register a tax ID and provision the matching liability and receivable accounts.

  • update_tax_registrationwrites

    Update a registration.

  • delete_tax_registrationwrites

    Remove a registration.

  • preview_invoice_tax

    Compute tax for hypothetical invoice lines without persisting anything.

  • search_india_hsn_sac_codes

    HSN/SAC code lookup. India organizations only.

  • suggest_india_gst_rate

    AI-assisted GST rate from an HSN/SAC code. India organizations only.

Catalog

Reusable products and services used on sales invoice lines.

  • list_items

    Active catalog items.

  • create_itemwrites

    Create a catalog item.

  • create_itemswrites

    Create 1–1000 catalog items.

  • update_itemwrites

    Update a catalog item.

  • archive_itemwrites

    Soft-delete a catalog item.

Drive and documents

The workspace's document store and its email intake inbox.

  • list_drive

    Folders and files in a folder, or the organization root.

  • list_drive_folders

    Flat folder list for move pickers and breadcrumbs.

  • create_drive_folderwrites

    Create a folder.

  • update_drive_folderwrites

    Rename or move a folder. Cycles and name clashes are rejected.

  • delete_drive_folderwrites

    Delete a folder, only when it is empty.

  • get_drive_file_text

    UTF-8 text of a CSV or TXT file for preview.

  • update_drive_filewrites

    Rename or move a file.

  • delete_drive_filewrites

    Delete a file.

  • get_file_download_url

    Signed URL for downloading a file.

  • list_email_intake_sources

    Documents received through the organization's email inbox.

  • get_email_intake_source

    Fetch a single intake document.

Resources

The server also exposes documents a client can read for context before it starts posting entries.

  • doc://companystack/bookkeeping-playbook

    Bookkeeping playbook

    How to book common transactions correctly in double entry.

  • doc://companystack/new-user-playbook

    New user setup playbook

    Opening balances and first-run setup for a fresh workspace.

  • doc://companystack/api-reference

    API reference

    Generated index of every tool the server currently exposes.

Prefer a plain HTTP API?

Every MCP tool is generated from the same OpenAPI description that powers the REST API. Browse it at the API reference, authenticated with an organization API key.