Accounting data
Send a business's accounting reports, as your accounting integration returns them, and Slate sizes the business's pre-approval from its books. No credit check, no manual review: Slate reads the reports, checks there is enough history, and issues an offer sized from its accounting data. If the business has no offer yet, this is its first one; if it already has one, the new offer replaces it and the previous one is no longer valid. Send more later (a new month, a correction, a report you didn't have) and Slate reads everything it holds again.
You send the reports as your accounting integration returns them, unchanged; Slate sets up the format your integration uses with you before you start, so there's nothing to convert on your side.
Amounts in the Slate API are integer cents (
10700000= $107,000.00). Authenticate every request with your private API key in thex-api-keyheader. Everything here works the same in sandbox (https://api-sandbox.tryslatehq.com) and live; accounting data sizing is turned on for your organization by Slate.
How it works
POST /customers ──► base offer, only with automatic pre-approvals
preapproval.created (basis: standard)
│
POST /attach-financial-data (documents) ──► stored as received, answered right away
│ business.financial-data.attached
▼ read in the background
enough data? ── no ──► the active offer, if any, stays preapproval.insufficient-data (what's missing)
│
yes ──► sized offer issued preapproval.created (basis: accounting_data)
if there was an active offer, preapproval.expired (the previous offer)
it's replaced and no longer valid
- Create the customer with your
externalId, as usual. If your organization has automatic pre-approvals, the business gets the base offer right away. - Send the accounting documents to
POST /attach-financial-data. Slate answers right away with what it recognized; reading happens in the background. - Slate analyzes everything it holds for the business and, when there is enough data, issues a sized offer. If the business already has an active offer, the new one replaces it. When there isn't enough data, it tells you what's missing.
- Read the offer from the webhooks or with
GET /v2/pre-approvals/{id}. It's valid for a month and renewed while the business doesn't apply.
Step 1 — Create the customer
curl -X POST "$BASE_URL/customers" \
-H "x-api-key: $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "BUSINESS",
"externalId": "cus_123",
"business": { "legalName": "Northwind Trading Ltd." }
}'
The accounting data is attached to this externalId, so create the customer before sending its documents (sending to an unknown externalId answers 404). See Capital for every customer field.
Step 2 — Send the accounting documents
Send each report in payload, exactly as your accounting integration returns it: the whole response, in the format agreed with Slate. Don't unwrap it, rename fields or convert amounts; Slate identifies each document from the response itself. For example:
curl -X POST "$BASE_URL/attach-financial-data" \
-H "x-api-key: $API_KEY" \
-H "Content-Type: application/json" \
-d '{
"externalId": "cus_123",
"documents": [
{
"payload": {
"status_code": 200,
"status": "OK",
"service": "xero",
"resource": "ProfitAndLosses",
"operation": "one",
"data": { "start_date": "2026-10-01", "end_date": "2026-10-31", "currency": "CAD", "income": { "...": "..." } }
}
},
{ "payload": { "status_code": 200, "service": "xero", "resource": "BalanceSheets", "data": [ "..." ] } }
]
}'
What to send
| Report | Needed for an offer |
|---|---|
| Profit and loss | Yes. One report per calendar month, at least the last 6 consecutive months |
| Balance sheet | Yes. Month-end balance sheets for the same months |
| Accounts receivable aging | Recommended |
| Accounts payable aging | Recommended |
| Chart of accounts | Recommended |
| Bank accounts | Recommended |
- One profit and loss per month. Request each month on its own, from the first day of the month to the last. A report spanning several months is stored but doesn't count as a month of history.
- Recent months. The latest month must be at most two months behind the current one (in November, send through September or later).
- Only months that have ended count. You can send the month to date; Slate stores it but leaves it out of the offer until the month ends, since a partial month would read as a drop in revenue.
- Currency. The offer is in the currency of the books, CAD or USD.
- Balance sheets: one document may hold several month-end reports; send one call per month or one with all of them.
- Recommended reports sharpen the read (collections, debt, liquidity). An offer can be sized without them.
- Anything else you send (invoices, bills, a report Slate doesn't read yet) is stored as received and answered with
recognized: false; it does no harm.
Batches, resends and corrections
- Up to 200 documents per call, all for the same business. Send a business's history in one call or in as many as you like: the analysis always covers everything Slate holds for the business, not just the latest call.
- Resending is safe. A document Slate already holds, byte for byte, isn't stored again and comes back with
duplicate: true. - Corrections replace. When a month is sent again with different figures (the books were adjusted), the newest version of that month is the one Slate uses. The same holds for each month-end balance sheet; for the agings, Slate uses the one with the latest as-of date.
The answer
The call answers right away, before the documents are read, with one entry per document, in the order sent:
{
"id": "0195f2b2-7c1a-7000-8000-0000000000f1",
"customerId": "0195f2b2-7c1a-7000-8000-000000000001",
"timeseries": [],
"documents": [
{ "id": "0195f2b2-…-0a1", "kind": "profit_and_loss", "format": "apideck.profit_and_loss", "recognized": true, "duplicate": false },
{ "id": "0195f2b2-…-0a2", "kind": "balance_sheet", "format": "apideck.balance_sheet", "recognized": true, "duplicate": false }
]
}
| Field | Meaning |
|---|---|
kind |
What Slate stored the document as: profit_and_loss, balance_sheet, ar_aging, ap_aging, chart_of_accounts, bank_accounts, invoices, bills, general_ledger, or unknown |
format |
The format Slate read the document as; null when it didn't identify the document |
recognized |
Whether Slate identified the document. Unrecognized documents are kept and read once Slate supports them |
duplicate |
Slate already held this exact document; nothing new was stored |
id identifies this send: every document it stored carries it. A document Slate already held (duplicate: true) keeps the send that first stored it. A 400 means the body is invalid: no documents (and no timeseries), more than 200 documents, or a payload that isn't a JSON object.
Webhook — business.financial-data.attached confirms the call: data.id is the send's id and data.documentIds lists the documents it stored new. A send that only repeats documents Slate already holds stores nothing and sends no webhook.
Step 3 — Slate sizes the offer
Every send with new documents starts an analysis of everything Slate holds for the business. It takes seconds; the result arrives as webhooks.
When there is enough data, Slate sizes the offer from the business's revenue, margins, liquidity, debt, collections and trend, and issues a new offer:
preapproval.createdfor the new one, which readsbasis: "accounting_data",preapproval.expiredfor the offer it replaces, if the business had one (the base offer, or an earlier sized one). The replaced offer is no longer valid.
A sized offer is never below a minimum agreed with Slate. With enough data, the books set the amount, so a sized offer can be lower than the base offer it replaces. When newer data sizes the same amount, the offer stays as it is and nothing is sent.
When there isn't, the active offer, if any, stays and Slate sends preapproval.insufficient-data with what's missing, so the business or its accounting firm can send it:
{
"event_type": "preapproval.insufficient-data",
"data": {
"id": "0195f2b2-7c1a-7000-8000-000000000001",
"externalId": "cus_123",
"preApprovalId": "0195f2b2-7c1a-7000-8000-0000000000aa",
"missing": [
{
"code": "pnl_months_below_minimum",
"detail": "4 of 6 consecutive months (2026-07 to 2026-10); missing 2026-05, 2026-06."
}
]
},
"timestamp": "2026-11-18T20:06:11.587Z"
}
data.id is the customer id and data.preApprovalId the active offer, if any (null otherwise). The codes:
| Code | Meaning | What to send |
|---|---|---|
pnl_missing |
No monthly profit and loss received | The monthly profit and loss for the last 6 months |
pnl_months_below_minimum |
Fewer than 6 consecutive months, counting back from the latest | The months listed in detail |
pnl_not_recent |
The latest month is more than 2 months old | The months since, as listed in detail |
balance_sheet_missing |
No balance sheet received | Month-end balance sheets for the same months |
currency_not_offered |
The books are in a currency Slate doesn't make offers in (CAD and USD) | Talk to Slate |
Codes are stable; new ones may be added. The event is sent after each analysis that ends short, so a new send that still isn't enough tells you again.
What Slate leaves alone
- An application in progress. While the business has an application in progress or approved, its offer is frozen: new data is stored and read, but the offer it applied with doesn't change.
- A recent decline. For 60 days after a declined application, no new offer is made.
- An offer made by hand (by your team, or by Slate with its own message) is never replaced by a sized one.
Step 4 — Read the offer
curl "$BASE_URL/v2/pre-approvals/$PRE_APPROVAL_ID" -H "x-api-key: $API_KEY"
{
"id": "0195f2b2-7c1a-7000-8000-0000000000bb",
"customerId": "0195f2b2-7c1a-7000-8000-000000000001",
"externalId": "cus_123",
"status": "ACTIVE",
"type": "credit_line",
"amount": 10700000,
"currency": "CAD",
"basis": "accounting_data",
"expiresAt": "2026-12-19T07:00:00.000Z",
"origin": "slate",
"description": "Sized from the financials your accountant shared.",
"repaymentFrequency": 1,
"repaymentFrequencyUnit": "month",
"createdAt": "2026-11-18T20:06:11.587Z"
}
| Field | Meaning |
|---|---|
basis |
standard: the base offer (or one set by hand). accounting_data: sized from the accounting data you sent |
description |
The message shown to the business with the offer. A sized offer reads "Sized from the financials your accountant shared." |
status |
ACTIVE is the business's current offer. A replaced or expired offer reads EXPIRED; one an application used reads CONSUMED |
expiresAt |
When the offer stops being valid (see below) |
GET /v2/pre-approvals?externalId=cus_123&status=ACTIVE lists the business's current offer, with the same fields. Read-only API keys can use both.
Expiry and renewal
An offer is valid for 30 days, until the end of that day (expiresAt is the instant it ends). When it expires:
- No application in progress: Slate replaces it with a new offer for another month, sized again from everything it holds. You get
preapproval.expiredandpreapproval.created, as for any replacement. When the data isn't enough, the new offer is at the base amount with automatic pre-approvals; without them, the offer expires (preapproval.expired) and no new one is made. - An application in progress: the offer stays until the application ends.
- An offer made by hand, or a recent decline: it expires (
preapproval.expired) and no new one is made.
Businesses whose books you can't send by API
A business whose books aren't in a system your accounting integration connects can send the profit and loss and balance sheet its accountant exported, as PDF or CSV. These go through the partner dashboard, not the API:
- In Customers, open Import → Accountant statements (PDF or CSV).
- Choose the business and drop its files: at least the last 6 months of profit and loss, by month, and the latest month-end balance sheet. Up to 20 files of 20 MB each.
- Slate's team enters the figures. It takes longer than accounting data sent by API.
You get the same webhooks as for an API send: business.financial-data.attached when the files arrive (data.documentIds lists one id per file), then preapproval.created with the sized offer, or preapproval.insufficient-data with what's missing, once the figures are entered. The same rules apply: 6 consecutive recent months and a balance sheet.
Webhooks summary
| Event | When |
|---|---|
preapproval.created |
The base offer when the customer is created (with automatic pre-approvals); a sized offer; a renewal |
business.financial-data.attached |
A send was stored |
preapproval.insufficient-data |
An analysis ended without enough data; what's missing |
preapproval.expired |
An offer was replaced (by a sized one or a renewal) or expired |
See Webhooks for signatures and the full catalog.