gl-importer-mcp

v0.1.1
com.synder/gl-importer-mcp Checked 44 minutes ago Published 5 months ago

Import CSV/XLSX accounting data into QuickBooks Online or Xero via the Synder Importer API.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

account_get

Returns the current Synder Importer account: email, name, status, subscription, and connected-company count. Call this first to verify the IMPORTER_API_TOKEN is valid.

companies_list

Lists all accounting companies connected to the Importer account (QuickBooks Online via 'intuit', Xero via 'xero'). Use the returned 'id' as companyId for downstream tools.

settings_get

Returns per-company import settings (dateFormat, document-number behavior, product/account auto-creation, duplicate-skip). Check dateFormat before importing — CSV date columns must match.

ParameterTypeDescription
companyId *stringCompany id from companies_list.

settings_update

Updates per-company import settings. Pass only the fields you want to change inside 'settings' (e.g. { dateFormat: 'dd/MM/yyyy' }). Fetch current values with settings_get first so you don't clobber unrelated fields. Returns the updated settings.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
settings *objectSettings patch. Common fields: dateFormat ('MM/dd/yyyy' | 'dd/MM/yyyy' | 'yyyy-MM-dd'), incrementDocNumber, createMissingProducts, createMissingAccounts, skipDuplicates.

entities_list

Lists importable entity types for a company (Invoice, Bill, JournalEntry, Customer, Vendor, etc.). Use the returned 'name' as entityName for fields_get and import tools.

ParameterTypeDescription
companyId *stringCompany id from companies_list.

fields_get

Returns the field schema for an entity in a company: every field with its type, required flag, alternativeTitles, and predefinedValues. Use to build or verify a mapping before running an import.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
entityName *stringEntity name from entities_list (e.g., 'Invoice', 'Bill').

mappings_list

Lists field mappings saved for a company. Each mapping is reusable across imports of the same entity type.

ParameterTypeDescription
companyId *stringCompany id from companies_list.

mapping_create

Creates a new field mapping for an entity (e.g. 'Journal Entry', 'Bill', 'Invoice'). Look up valid target fields with fields_get first. Returns the created mapping including its id.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
entityName *stringEntity this mapping targets — must match entities_list output (e.g. 'Journal Entry').
fields *arrayField mappings. Each entry maps a CSV column or a constant to an Importer target field.
title *stringHuman-readable mapping name.

mapping_update

Replaces an existing mapping in full. Fetch the current mapping with mappings_list first and send the whole desired shape — this is a PUT, not a patch. Returns the updated mapping.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
entityName *stringEntity this mapping targets — must match entities_list output.
fields *arrayField mappings (full replacement).
mappingId *stringMapping id from mappings_list.
title *stringHuman-readable mapping name.

mapping_delete

Deletes a saved mapping. Irreversible. Imports that referenced this mapping keep their historical record but new imports can no longer pick it.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
mappingId *stringMapping id from mappings_list.

imports_list

Lists recent imports for a company with status and timestamps. Use to find an importId for status / results / revert / cancel.

ParameterTypeDescription
companyId *stringCompany id from companies_list.

import_status

Returns a single import's current status and summary (total / succeeded / failed / warnings). Status lifecycle: SCHEDULED → IN_PROGRESS → FINISHED | FINISHED_WITH_WARNINGS | FAILED | CANCELED. FINISHED can transition to REVERTING → REVERTED.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
importId *stringImport id from imports_list.

import_results

Returns per-row results for a finished import. Filter by 'type' (INFO / WARNING / ERROR) to surface only failures. Paginated — defaults to 20 rows per page, max 100.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
importId *stringImport id from imports_list.
pageintegerPage number (1-indexed). Default 1.
perPageintegerRows per page. Default 20, max 100.
typestringOptional: filter rows by result type.

import_execute

Uploads a CSV/XLSX file and starts an import using an existing mapping. The MCP server reads the file from disk — pass an absolute path. Returns the created import object including importId. Status starts as SCHEDULED — poll import_status or use import_wait. Limits: .csv/.xlsx/.xls only, 50MB max.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
entityName *stringEntity to import as — must match entities_list (e.g. 'Journal Entry').
filePath *stringAbsolute path to a .csv, .xlsx, or .xls file on the machine running the MCP server.
mappingId *stringMapping id from mappings_list to apply to the file.

import_auto

Uploads a file and asks the server to auto-map columns to the target entity. Set dryRun=true to get the proposed mapping back without creating an import — useful for showing the user what will happen and asking 'does this look right?' before committing. Set dryRun=false (default) to auto-map and import in one call.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
entityName *stringEntity to import as — must match entities_list output.
filePath *stringAbsolute path to a .csv, .xlsx, or .xls file.
dryRunbooleanIf true, returns proposed mapping without starting an import. Default false.

import_cancel

Cancels a SCHEDULED or IN_PROGRESS import. Already-imported rows are NOT rolled back — use import_revert for that. Returns the updated import status.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
importId *stringImport id from imports_list.

import_revert

Reverts a FINISHED or FINISHED_WITH_WARNINGS import — deletes the QuickBooks/Xero entries the import created, using their live SyncTokens. Status transitions FINISHED → REVERTING → REVERTED. Confirm with the user before calling — irreversible from their perspective.

ParameterTypeDescription
companyId *stringCompany id from companies_list.
importId *stringImport id from imports_list.

import_wait

Polls import_status until the import reaches a terminal state (FINISHED, FINISHED_WITH_WARNINGS, FAILED, CANCELED, REVERTED). Exponential backoff (2s → 1.5× → cap 30s). Default timeout 600s — if exceeded, returns { status: 'POLLING', importId, lastSeen } so the LLM can re-call. Includes a per-type result count summary on terminal states (INFO / WARNING / ERROR; null if the server didn't return totals).

ParameterTypeDescription
companyId *stringCompany id from companies_list.
importId *stringImport id from imports_list or import_execute.
timeoutSecondsintegerMax seconds to wait before returning POLLING. Default 600.

import_csv

Happy-path CSV/XLSX importer. Two-step: first call (without confirmed) auto-resolves the company, uploads the file, and returns the server's proposed mapping plus any missingRequired fields — show this to the user. Re-call with confirmed=true (and the same filePath) to run the real import and poll until it terminates. Returns { stage: 'DRY_RUN' | 'DONE', importId?, status, summary?, proposedMapping?, missingRequired? }.

ParameterTypeDescription
entityName *stringEntity to import as — match entities_list (e.g. 'Journal Entry').
filePath *stringAbsolute path to a .csv, .xlsx, or .xls file.
companyIdstringOptional. If omitted and exactly one ACTIVE company exists, it's picked automatically.
confirmedbooleanSet true on the second call to commit the import. Default false (dry-run only).
timeoutSecondsintegerForwarded to import_wait on the confirmed call. Default 600.