Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
BILLY_LOCALENoLocale: en_US, da_DK, fr_FR, nl_NL, de_DE
BILLY_BASE_URLNoBase URL for Billy APIhttps://api.billysbilling.com/v2
BILLY_WRITE_MODENoWrite mode: read-only, confirm (default), or fullconfirm
BILLY_ACCESS_TOKENYesBilly API access token (sent as X-Access-Token)
BILLY_ORGANIZATION_IDNoAuto-resolved when the token maps to one company

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
get_organizationA

Get the Billy organization (company) details: name, base currency, VAT settings, default payment terms, fiscal year, invoice numbering. Call this first to learn the organization ID and base currency used by other tools.

list_contactsA

List contacts (customers and suppliers) in Billy. Supports free-text search and filtering. Use this to find a contact ID before creating invoices or bills.

get_contactA

Get a single Billy contact by its ID, including full address and settings.

create_contactB

Create a new contact (customer or supplier) in Billy. Returns the created contact including its ID.

update_contactA

Update an existing Billy contact. Only provided fields are changed.

list_contact_personsB

List contact persons (names/emails used for sending invoices) belonging to a Billy contact.

create_contact_personA

Add a contact person (name and/or email) to an existing Billy contact. Emails are used to mail invoices.

list_productsA

List products in Billy. Use this to find a product ID before creating invoice lines. Supports free-text search.

get_productA

Get a single Billy product by ID, plus its per-currency prices.

create_productA

Create a product in Billy, optionally with per-currency unit prices. Returns the created product including its ID.

update_productA

Update an existing Billy product. Only provided fields are changed. Providing prices replaces all existing prices.

list_invoicesA

List invoices in Billy with filters for customer, state, date range and free-text search. Returns invoices plus meta.paging.

get_invoiceA

Get a single Billy invoice by ID, including its lines, balance and paid status.

create_invoiceA

Create an invoice (or credit note) in Billy with one or more lines. Created as draft by default; pass state=approved to approve immediately (approval assigns the invoice number and books it). Amounts are in the invoice currency.

approve_invoiceA

Approve a draft Billy invoice (draft -> approved is the only allowed state change). Approval books the invoice; it cannot be reverted to draft.

delete_invoiceA

Delete a Billy invoice (drafts only; approved invoices must be voided/credited instead). Returns meta.deletedRecords.

create_bank_paymentA

Record a bank payment in Billy to mark an invoice or bill as (partially) paid. Creates a bankPayment associated with the subject via 'invoice:' or 'bill:'. For invoices money is deposited (debit); for bills it is withdrawn (credit). WARNING: this posts a real accounting transaction.

list_bank_paymentsA

List bank payments recorded in Billy. Useful to review what payments exist for reconciliation. NOTE: Billy only supports organizationId server-side for this endpoint; contactId/cashAccountId/date filters are applied client-side within the fetched page.

list_balance_modifiersA

List balance modifiers (payment associations) in Billy. Filter by subjectReference like 'invoice:' or 'bill:' to see which payments settled a specific invoice or bill. NOTE: subjectReference is not documented server-side; it is also enforced client-side within the fetched page.

list_billsA

List supplier bills (expenses) in Billy with filters for supplier, state, paid status, date range and free-text search.

get_billA

Get a single Billy bill by ID, including its lines, balance and paid status.

create_billA

Create a supplier bill (expense) in Billy with one or more lines coded to expense accounts. Created as draft by default; pass state=approved to book it immediately.

list_accountsA

List the chart of accounts in Billy. Use this to find account IDs for bill lines, product revenue accounts, and bank accounts for payments (look for isPaymentEnabled/isBankAccount).

get_accountA

Get a single account from the Billy chart of accounts by ID.

list_daybook_transactionsA

List daybook transactions (manual journal entries) in Billy, filterable by state and entry date range.

list_daybooksA

List daybooks in Billy. Find the daybook ID used for manual journal entries.

create_daybook_transactionA

Create a manual journal entry (daybook transaction) in Billy with balanced debit/credit lines. Validates balance client-side before asking for approval. Supports safe-retry deduplication via idempotencyKey. Created as draft by default; state=approved books it immediately.

void_daybook_transactionA

Void a daybook transaction (journal entry) in Billy. Irreversible — voided entries cannot be reinstated.

batch_void_daybook_transactionsA

Void many daybook transactions in one call with ONE user approval for the whole batch. Continues past individual failures and reports per-id results. Irreversible.

get_account_balancesA

Account balances / trial balance computed from postings. Ask "what is the balance of account 5211" → accountNos: ["5211"]. Omit account filters for a full trial balance. Bound with minEntryDate/maxEntryDate for speed — the tool fetches and aggregates all matching postings server-side.

list_postingsA

List ledger postings (individual debit/credit entries). For balances/aggregates use get_account_balances instead. Date/void/text filters are applied client-side within the fetched page — narrow with accountId.

list_transactionsA

List booked transactions. transactionNo/voucherNo filters are applied CLIENT-SIDE (Billy silently ignores them as query params) by scanning up to 5000 records — bound with dates when possible.

list_bank_linesA

List imported bank lines. Date and matched filters are applied client-side within the fetched page.

list_bank_line_matchesA

List bank line matches (bank reconciliation groupings). isApproved filter applied client-side within the page.

list_filesA

List files uploaded to Billy (receipts, invoices PDFs, etc.). Files are append-only via the API.

list_attachmentsA

List attachments (file↔record links). Filter by owner to see what's attached to a specific record; ownerReference is applied client-side within the page.

upload_fileA

Upload a local file (pdf/jpg/jpeg/png/gif ONLY — Billy rejects other types with a 422) to Billy and get its file ID. Files are append-only: they cannot be deleted or modified via the API afterwards. Use attach_file to link the uploaded file to a record.

attach_fileA

Attach an uploaded file to a Billy record (daybook transaction, invoice, or bill). Get the fileId from upload_file or list_files. Example: attach a receipt to journal entry #67 → ownerType 'daybookTransaction', ownerId ''.

execute_scriptA

Run a short JavaScript (ES2022, top-level await allowed) batch script against the Billy API — use for loops, aggregation and reconciliation instead of many single tool calls (e.g. void 30 entries, post 7 monthly journals, sum postings). In scope: billy (get(path,query?), post(path,body), put(path,body), del(path), request(method,path,{body,query}), fetchAll(path,resourceKey,query?,maxRecords?) [GET-only], getOrganizationId()) and console.log. Return a value or log results. Safety: every mutating HTTP call is logged server-side and the mutation log is ALWAYS returned, even if the script throws; dry_run=true simulates writes without executing them (and skips the approval prompt); in read-only mode non-GET calls are blocked; in confirm mode ONE user approval is requested upfront showing the full script. Limits: default 30s timeout, 50 API calls per run, output capped. Billy gotchas: POST/PUT bodies need singular-key wrapping ({ daybookTransaction: {...} }); Billy silently ignores undocumented query filters; use apiType as idempotency key on daybook transactions.

billy_raw_requestA

Escape hatch: call any Billy API v2 endpoint not covered by a dedicated tool. Examples: GET /currencies, /countries, /taxRates, /salesTaxReturns, /invoiceReminders, /files, /bankLines, /postings, /users. Write requests must wrap the body in a singular resource key, e.g. { "daybookTransaction": {...} }. WARNING: POST/PUT/DELETE have real accounting effects — prefer dedicated tools when available. Non-GET methods require BILLY_WRITE_MODE=confirm (user approval) or full; in read-only mode only GET is allowed. CAUTION: Billy SILENTLY IGNORES undocumented query params (no error, just unfiltered results) — cross-check filters against docs/billy-api.md before relying on them.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Thourum/billy-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server