apideck-mcp-month-end-close
Month-end close snapshot (Apideck MCP)
When the user wants a one-shot financial snapshot, prefer apideck-month-end-close-check over fetching the four reports individually. The workflow fans out aged creditors, aged debtors, balance sheet, and profit-and-loss in parallel against the connected accounting service and returns one aggregated object.
When this is the right tool
| User intent | Tool |
|---|---|
| "Run the month-end close", "P&L plus balance sheet for last month", "Aged AP/AR snapshot as of March 31" | apideck-month-end-close-check ✓ |
| "Just the P&L" | accounting-profit-and-loss-get directly |
| "Just aged creditors" | accounting-aged-creditors-get directly |
| "Reconcile bank statements" | Out of scope — use the connector's native reconciliation |
IMPORTANT RULES
- READ-ONLY, idempotent. Safe to call repeatedly — no confirmation needed. The tool fetches data; it doesn't post anything.
- OMIT
report_as_of_dateto use today. Most users running a month-end ask for "last month", in which case pass an explicitYYYY-MM-DDlike"2026-03-31". - EXPECT partial results. Connector coverage varies — Odoo doesn't implement aged-creditors, Moneybird doesn't implement balance-sheet, etc. The workflow returns
{ unsupported: true, reason }for steps the connector can't fulfill, plus a top-levelwarnings[]array. Surface these to the user instead of treating them as failures. isError: trueonly fires when every report failed — typically a missing connection or expired credentials. Partial snapshots come back asisError: falseso the agent can still extract value.
Argument map
| Arg | Required | Default | Notes |
|---|---|---|---|
report_as_of_date |
no | today (YYYY-MM-DD) | Cutoff date for aged reports + balance sheet. |
x-apideck-service-id |
no | first accounting connection | E.g. "xero", "quickbooks". |
Result shape
Full success
{
"report_as_of_date": "2026-03-31",
"service_id": "xero",
"aged_creditors": { "summary": [...] },
"aged_debtors": { "summary": [...] },
"balance_sheet": { "assets": 100000, ... },
"profit_and_loss":{ "revenue": 250000, ... }
}
Partial — some reports unsupported
{
"report_as_of_date": "2026-03-31",
"service_id": "odoo",
"aged_creditors": { "unsupported": true, "reason": "Aged-creditors not implemented for Odoo" },
"aged_debtors": { "unsupported": true, "reason": "..." },
"balance_sheet": { "assets": 100000, ... },
"profit_and_loss":{ "revenue": 250000, ... },
"warnings": [
"aged_creditors: unsupported on odoo (...)",
"aged_debtors: unsupported on odoo (...)"
]
}
isError: false — two reports came back, that's still useful.
Total failure
{
"report_as_of_date": "2026-03-31",
"service_id": null,
"aged_creditors": { "error": "..." },
"aged_debtors": { "error": "..." },
"balance_sheet": { "error": "..." },
"profit_and_loss":{ "error": "..." },
"warnings": [...]
}
With isError: true. Usually a missing connection — surface the elicitation URL.
Worked example
User: "Give me a month-end snapshot for March 2026 from QuickBooks."
{
"name": "apideck-month-end-close-check",
"arguments": {
"report_as_of_date": "2026-03-31",
"x-apideck-service-id": "quickbooks"
}
}
Then summarize for the user, calling out any unsupported rows distinctly:
On 2026-03-31 in QuickBooks: revenue $250K, total assets $100K. Aged creditors / aged debtors aren't supported by this connector — pull those from the Bills-list and Invoices-list reports if you need them.
Common failure modes
| Symptom | Cause | Fix |
|---|---|---|
All four reports unsupported |
Connector doesn't implement these (e.g. Odoo without the Reports module) | Surface the limitation; suggest aggregating from accounting-bills-list + accounting-invoices-list instead |
UnsupportedFiltersError on a report |
Connector rejects filter[report_as_of_date] or filter[end_date] |
Connector quirk — currently surfaces as unsupported with the upstream message |
UrlElicitationRequiredError |
Connection expired/missing | Surface consent URL, retry |
Related
apideck-mcp— front-door skill- Workflow source: src/gen/workflows/monthEndClose.ts
More from apideck-libraries/api-skills
apideck-connector-coverage
Check Apideck connector API coverage before building integrations. Use when determining which operations a connector supports, comparing connector capabilities, or diagnosing why an API call fails with a specific connector. Teaches agents to query the Connector API for real-time coverage data.
18apideck-best-practices
Best practices for building Apideck integrations. Covers authentication patterns, pagination, error handling, connection management with Vault, webhook setup, and common pitfalls. Use when designing or reviewing any Apideck integration regardless of language.
18apideck-rest
Apideck Unified REST API reference for any language. Use when building integrations with accounting software (QuickBooks, Xero, NetSuite), CRMs (Salesforce, HubSpot, Pipedrive), HRIS platforms (Workday, BambooHR), file storage (Google Drive, Dropbox, Box), ATS systems (Greenhouse, Lever), e-commerce, or any of Apideck's 200+ connectors using direct HTTP calls. Covers authentication headers, CRUD operations, cursor-based pagination, filtering, sorting, error handling, rate limiting, pass-through parameters, and webhooks. Language-agnostic — works with curl, fetch, axios, httpx, or any HTTP client.
16apideck-portman
API contract testing with Portman by Apideck. Use when generating Postman collections from OpenAPI specs, writing contract tests, variation tests, integration tests, fuzz testing, or setting up CI/CD API test pipelines. Portman converts OpenAPI 3.x specs into Postman collections with auto-generated test suites.
14apideck-node
Apideck Unified API integration patterns for TypeScript and Node.js. Use when building integrations with accounting software (QuickBooks, Xero, NetSuite), CRMs (Salesforce, HubSpot, Pipedrive), HRIS platforms (Workday, BambooHR), file storage (Google Drive, Dropbox, Box), ATS systems (Greenhouse, Lever), e-commerce, or any of Apideck's 200+ connectors. Covers the @apideck/unify SDK, authentication, CRUD operations, pagination, filtering, webhooks, and Vault connection management.
14apideck-codegen
Generate typed API clients from Apideck OpenAPI specs using code generators. Use when the user wants to generate custom SDK clients, typed models, API stubs, or server scaffolding from Apideck's published OpenAPI specifications. Covers openapi-generator, Speakeasy, and Postman import workflows.
14