Developers
One organisation's CRM over HTTP. Every request is scoped to the key's organisation; there is no parameter that widens that.
This page is rendered from the same description a tool reads: https://minicrm.dfieldsolutions.hu/api/v1/openapi.json
Authentication
Create a key under Settings → API and send it on every request:
Authorization: Bearer mck_…
A key's scope is read or write; the write endpoints need write. A key may also carry an expiry and an IP allow-list (CIDR).
Limits
120 requests per minute per key. Responses carry X-RateLimit-Remaining, and a 429 carries Retry-After. GET /me reports the remaining budget without spending it.
Idempotency
Every writing endpoint accepts an Idempotency-Key header. A repeat with the same key within 24 hours gets the first response back (Idempotency-Replayed: true) and creates nothing.
Idempotency-Key: order-10042
Errors
Every error is one JSON object: { "error": "<code>", "detail": ... }.
| Code | Status | Meaning |
|---|---|---|
| missing_bearer_token | 401 | No `Authorization: Bearer` header. |
| invalid_api_key | 401 | Unknown, revoked, or used from an address outside the key's allow-list. |
| expired_api_key | 401 | The key's `expires_at` has passed. |
| missing_scope:write | 403 | The key has only the `read` scope. |
| plan_refused | 403 | The plan is read-only (trial ended) or a counted limit is reached; `detail` carries the code. |
| not_found | 404 | No such record in this organisation — another organisation's id gets the same answer. |
| idempotency_in_progress | 409 | The first request with this `Idempotency-Key` is still running; retry after `Retry-After`. |
| email_already_exists | 409 | A live contact in this organisation already has that address. |
| validation_failed | 422 | The body failed validation; `detail` lists the issues. |
| no_fields_to_update | 422 | A PATCH with no recognised field. |
| rate_limited | 429 | More than 120 requests in a minute; honour `Retry-After`. |
| missing_scope:quotes:write | 403 | Creating or changing a quote needs the `quotes:write` scope. |
| missing_scope:invoices:write | 403 | Creating, changing, issuing or paying an invoice needs the `invoices:write` scope. |
| not_draft | 409 | The quote or invoice is no longer a draft; an issued invoice is reversed with a storno, never edited. |
| not_payable | 409 | A draft is not owed and a cancelled invoice or a storno is owed by nobody. |
| not_issuable | 422 | The draft cannot become a document yet; `detail` says why (e.g. `RATE_REQUIRED`, `VAT_REASON_REQUIRED`). |
| invalid_target_url | 422 | A hook target must resolve to a public address, and be https when the CRM is; `detail` says which rule. |
| too_many_hooks | 409 | This API key already holds the maximum number of hook subscriptions. |
| unknown_event | 404 | Not an event in the webhook catalogue. |
Endpoints
contacts
- get
/api/v1/contactsreadList contactsParameters: email (query)status (query: lead|prospect|customer|inactive)updated_since (query)q (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/contactswriteCreate a contactParameters: Idempotency-Key (header)Body: ContactInputResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.409 A live contact already has that email.422 Validation failed. - get
/api/v1/contacts/{id}readOne contactParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/contacts/{id}writeUpdate a contactParameters: id (path)Idempotency-Key (header)Body: ContactInputResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - delete
/api/v1/contacts/{id}writeArchive a contactParameters: id (path)Idempotency-Key (header)Responses: 204 Archived (or removed).401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
companies
- get
/api/v1/companiesreadList companiesParameters: q (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/companieswriteCreate a companyParameters: Idempotency-Key (header)Body: CompanyCreateResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/companies/{id}readOne companyParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/companies/{id}writeUpdate a companyParameters: id (path)Idempotency-Key (header)Body: CompanyPatchResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - delete
/api/v1/companies/{id}writeArchive a companyParameters: id (path)Idempotency-Key (header)Responses: 204 Archived (or removed).401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
deals
- get
/api/v1/dealsreadList dealsParameters: status_kind (query: open|won|lost)contact_id (query)pipeline_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/dealswriteOpen a dealWithout `pipeline_id` the deal goes into the organisation's first pipeline; without `status_id` into that pipeline's first open stage.
Parameters: Idempotency-Key (header)Body: DealCreateResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/deals/{id}readOne dealParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/deals/{id}writeUpdate a deal's fieldsThe stage is not a field: move it with `POST /deals/{id}/status`.
Parameters: id (path)Idempotency-Key (header)Body: DealPatchResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - delete
/api/v1/deals/{id}writeArchive a dealParameters: id (path)Idempotency-Key (header)Responses: 204 Archived (or removed).401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - post
/api/v1/deals/{id}/statuswriteMove a deal to another stageWrites the stage history, stamps `closed_at`, starts automations waiting on the stage and emits `deal.status_changed` (plus `deal.won` / `deal.lost`). `status_id` must belong to the deal's own pipeline.
Parameters: id (path)Idempotency-Key (header)Body: DealStatusResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
tasks
- get
/api/v1/tasksreadList tasksParameters: done (query: true|false)priority (query: low|normal|high|urgent)assignee_id (query)entity_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/taskswriteCreate a taskParameters: Idempotency-Key (header)Body: TaskCreateResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/tasks/{id}readOne of tasksParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/tasks/{id}writeUpdate a taskParameters: id (path)Idempotency-Key (header)Body: TaskPatchResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - delete
/api/v1/tasks/{id}writeDelete a taskParameters: id (path)Idempotency-Key (header)Responses: 204 Archived (or removed).401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - post
/api/v1/tasks/{id}/completewriteMark a task doneIdempotent: an already-completed task keeps its original time and emits nothing.
Parameters: id (path)Idempotency-Key (header)Responses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
quotes
- get
/api/v1/quotesreadList quotesParameters: status (query: draft|sent|accepted|rejected|expired|cancelled)contact_id (query)company_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/quotesquotes:writeCreate a draft quoteLines are priced by the same arithmetic the editor and the PDF use (rounded per line, then summed). A zero VAT rate needs a `vat_reason`. The quote is a draft; sending it stays a button somebody presses.
Parameters: Idempotency-Key (header)Body: QuoteCreateResponses: 201 Created.401 Not authenticated.403 Missing the `quotes:write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/quotes/{id}readOne of quotesParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/quotes/{id}quotes:writeChange a draft quoteDrafts only — a quote already in a customer's inbox is changed on the screen, where sending it again freezes a new revision. Fields left out keep their value; `items`, when sent, replaces every line.
Parameters: id (path)Idempotency-Key (header)Body: QuotePatchResponses: 200 Updated.401 Not authenticated.403 Missing the `quotes:write` scope, or refused by the plan.404 Not found.409 No longer a draft.422 Validation failed.
invoices
- get
/api/v1/invoicesreadList invoicesParameters: status (query: draft|issued|partial|paid|overdue|cancelled)kind (query: normal|storno|corrective|proforma|advance)contact_id (query)company_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/invoicesinvoices:writeCreate a draft invoiceWritten by the same code as the invoice editor: lines priced per line by `lib/money.ts`, the buyer's VAT exemption checked, the addressee frozen. No number — a draft is not a document; issue it with `POST /invoices/{id}/issue`. Dates default to today in the organisation's timezone and the due date to its payment terms.
Parameters: Idempotency-Key (header)Body: InvoiceCreateResponses: 201 Created.401 Not authenticated.403 Missing the `invoices:write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/invoices/{id}readOne of invoicesParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/invoices/{id}invoices:writeChange a draft invoiceDrafts only. Fields left out keep their value; `items`, when sent, replaces every line.
Parameters: id (path)Idempotency-Key (header)Body: InvoicePatchResponses: 200 Updated.401 Not authenticated.403 Missing the `invoices:write` scope, or refused by the plan.404 Not found.409 No longer a draft.422 Validation failed. - post
/api/v1/invoices/{id}/issueinvoices:writeIssue a draft invoiceAllocates the number from the series of the invoice's kind and the year of its issue date, in the transaction that writes it, and emits `invoice.issued`. The body is optional; a foreign-currency invoice without `exchange_rate` uses the central bank's rate for the fulfilment date.
Parameters: id (path)Idempotency-Key (header)Body: InvoiceIssueResponses: 200 Updated.401 Not authenticated.403 Missing the `invoices:write` scope, or refused by the plan.404 Not found.409 No longer a draft.422 Validation failed. - post
/api/v1/invoices/{id}/paymentsinvoices:writeRecord a payment against an issued invoiceSend an `Idempotency-Key`: a retried payment is money counted twice.
Parameters: id (path)Idempotency-Key (header)Body: PaymentCreateResponses: 201 Recorded; the invoice's status follows from the sum of its payments.401 Not authenticated.403 Missing the `invoices:write` scope, or refused by the plan.404 Not found.409 Not payable (a draft, cancelled, or a storno).422 Validation failed.
products
- get
/api/v1/productsreadList productsParameters: active (query: true|false)category (query)stock (query: untracked|out|low|ok)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/productswriteCreate a productParameters: Idempotency-Key (header)Body: ProductCreateResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/products/{id}readOne of productsParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/products/{id}writeUpdate a productParameters: id (path)Idempotency-Key (header)Body: ProductPatchResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed. - post
/api/v1/products/{id}/stockwriteMove stock, or set it to a countStock is a ledger, not a field: `delta` records a movement (restock, return, adjust) and `count` a stocktake as the difference; `count: null` stops tracking. Send one of the two. Refused with 409 when a movement would take stock below zero or the product is not tracked.
Parameters: id (path)Idempotency-Key (header)Body: StockMoveResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
orders
- get
/api/v1/ordersreadList ordersParameters: fulfilment (query: new|confirmed|shipped|delivered|cancelled)contact_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - get
/api/v1/orders/{id}readOne of ordersParameters: id (path)Responses: 200 The record.404 Not found.
records
- get
/api/v1/recordsreadList recordsParameters: type (query)contact_id (query)company_id (query)deal_id (query)limit (query)offset (query)Responses: 200 The page.401 Not authenticated.429 Rate limited. - post
/api/v1/recordswriteCreate a record of a custom type`type` is the record type's key. Keys in `custom` the type does not define are dropped and listed in `ignored_fields` in the response.
Parameters: Idempotency-Key (header)Body: RecordCreateResponses: 201 Created.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.422 Validation failed. - get
/api/v1/records/{id}readOne of recordsParameters: id (path)Responses: 200 The record.404 Not found. - patch
/api/v1/records/{id}writeUpdate a recordParameters: id (path)Idempotency-Key (header)Body: RecordPatchResponses: 200 Updated.401 Not authenticated.403 Missing the `write` scope, or refused by the plan.404 Not found.422 Validation failed.
meta
- get
/api/v1/mereadThe key, its organisation and the remaining rate budgetResponses: 200 Who is asking. - get
/api/v1/eventsreadPoll the organisation's event historyFor Zapier, Make and anything else that would rather poll than host an endpoint. Send back `next_cursor` as `since` on the next call. The same events, in the same shape, as the webhooks deliver; thirty days are kept.
Parameters: since (query)event (query: contact.created|contact.updated|deal.created|deal.status_changed|deal.won|deal.lost|quote.accepted|quote.rejected|invoice.paid|form.submitted|task.completed|webshop.order|record.created|record.updated|company.created|company.updated|deal.updated|task.created|quote.created|product.created|product.updated|invoice.issued|lead.received|call.ended|call.missed)limit (query)Responses: 200 Events after the cursor, oldest first.400 `since` is not a number, or `event` is not in the catalogue. - get
/api/v1/openapi.jsonThis documentResponses: 200 The OpenAPI 3.1 document.
Webhooks
A webhook is a URL and a list of events, under Settings → API. Every delivery is signed; the secret can be rotated with a 24-hour overlap.
X-MiniCRM-Signaturet=<unix seconds>,v1=<hex hmac-sha256>[,v1=<hex hmac-sha256>]HMAC-SHA256(secret, <t>.<raw body>)After a secret rotation both the new and the previous secret sign every delivery for 24 hours, so the header carries two `v1` values. Verify against the secret you hold and accept if any `v1` matches.
contact.created{ "event": "contact.created", "data": { "id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "first_name": "Péter", "last_name": "Kovács", "email": "peter.kovacs@example.hu", "phone": "+36 20 123 4567", "company_id": null, "status": "lead", "source": "api", "custom": {}, "created_at": "2026-09-07T10:12:00.000Z" } }contact.updated{ "event": "contact.updated", "data": { "id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "first_name": "Péter", "last_name": "Kovács", "email": "peter.kovacs@example.hu", "status": "customer", "updated_at": "2026-09-08T08:00:00.000Z" } }deal.created{ "event": "deal.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Webshop bevezetés", "value": 1250000, "currency": "HUF", "pipeline_id": "c0ffee00-0000-4000-8000-000000000001", "status_id": "c0ffee00-0000-4000-8000-000000000002", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "expected_close_date": "2026-10-31" } }deal.status_changed{ "event": "deal.status_changed", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Webshop bevezetés", "status_id": "c0ffee00-0000-4000-8000-000000000003", "status_kind": "open", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }deal.won{ "event": "deal.won", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Webshop bevezetés", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "lost_reason": null } }deal.lost{ "event": "deal.lost", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Webshop bevezetés", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "lost_reason": "Túl drága" } }quote.accepted{ "event": "quote.accepted", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "number": "AJ-2026-0042", "total": 1587500, "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }quote.rejected{ "event": "quote.rejected", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "number": "AJ-2026-0042", "total": 1587500, "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }invoice.paid{ "event": "invoice.paid", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "number": "SZ-2026-0107", "total": 1587500, "paid_amount": 1587500, "currency": "HUF", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }form.submitted{ "event": "form.submitted", "data": { "form_id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "fields": { "email": "peter.kovacs@example.hu", "message": "Érdekel az ajánlat." } } }task.completed{ "event": "task.completed", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Visszahívás", "entity_type": "contact", "entity_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }webshop.order{ "event": "webshop.order", "data": { "order_id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "external_id": "10042", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "deal_id": "c0ffee00-0000-4000-8000-000000000004", "total": 24900, "currency": "HUF" } }record.created{ "event": "record.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "type_id": "c0ffee00-0000-4000-8000-000000000005", "type_key": "ingatlan", "title": "Budapest, XIII. ker., 62 m²", "owner_id": null } }record.updated{ "event": "record.updated", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "type_id": "c0ffee00-0000-4000-8000-000000000005", "type_key": "ingatlan", "title": "Budapest, XIII. ker., 62 m²", "owner_id": null } }company.created{ "event": "company.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "name": "Minta Kft.", "domain": "minta.hu", "email": "info@minta.hu", "vat_number": "12345678-2-41", "city": "Budapest", "country": "HU", "custom": {}, "created_at": "2026-09-07T10:12:00.000Z" } }company.updated{ "event": "company.updated", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "name": "Minta Kft.", "domain": "minta.hu", "city": "Debrecen", "updated_at": "2026-09-08T08:00:00.000Z" } }deal.updated{ "event": "deal.updated", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Webshop bevezetés", "value": 1400000, "currency": "HUF", "status_id": "c0ffee00-0000-4000-8000-000000000002", "status_kind": "open", "expected_close_date": "2026-11-15" } }task.created{ "event": "task.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "title": "Visszahívás", "type": "call", "priority": "high", "due_at": "2026-09-09T09:00:00.000Z", "entity_type": "contact", "entity_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }quote.created{ "event": "quote.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "number": "AJ-2026-0042", "status": "draft", "total": 1587500, "currency": "HUF", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a" } }product.created{ "event": "product.created", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "sku": "WEB-001", "name": "Webshop bevezetés", "unit": "db", "unit_price": 1250000, "currency": "HUF", "vat_rate": 27, "active": true } }product.updated{ "event": "product.updated", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "sku": "WEB-001", "name": "Webshop bevezetés", "unit_price": 1350000, "active": true } }invoice.issued{ "event": "invoice.issued", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "number": "SZ-2026-0107", "kind": "normal", "issue_date": "2026-09-07", "due_date": "2026-09-15", "total": 1587500, "currency": "HUF", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "company_id": null } }lead.received{ "event": "lead.received", "data": { "provider": "facebook", "lead_id": "1234567890123456", "form_id": "987654321098765", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "created": true } }call.ended{ "event": "call.ended", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "provider": "aircall", "direction": "inbound", "status": "completed", "duration_seconds": 185, "from_number": "+36 20 123 4567", "to_number": "+36 1 234 5678", "contact_id": "8d1e2f3a-4b5c-4d6e-8f9a-0b1c2d3e4f5a", "recording_url": "https://assets.aircall.io/calls/123/recording" } }call.missed{ "event": "call.missed", "data": { "id": "3f2c9a4e-7b1d-4c2a-9e6f-1a2b3c4d5e6f", "provider": "twilio", "direction": "inbound", "status": "missed", "duration_seconds": 0, "from_number": "+36 20 123 4567", "to_number": "+36 1 234 5678", "contact_id": null, "recording_url": null } }
Polling instead of receiving
Zapier, Make and friends would rather ask than host: GET /events?since=<cursor> returns the same events in the same shape. Send the response's next_cursor back as since.
GET /api/v1/events?since=0
→ { "data": [ { "id": "1042", "event": "contact.created", "data": {…}, "created_at": "…" } ],
"next_cursor": "1042", "has_more": false }MCP — AI assistants
The same API key, scopes and limits, over the Model Context Protocol. Add it as a remote MCP server and send the key as a Bearer token.
https://minicrm.dfieldsolutions.hu/api/mcp (MCP 2025-06-18)
search_contactsreadFind contacts by name, email, phone or company. Matches the same way the CRM's own search box does, so a partial Hungarian name works. Returns at most 25.get_contactreadOne contact in full, with its open deals, open tasks and the last few timeline entries. Use this before answering a question about a person — the search result is deliberately thin.list_dealsreadDeals in the pipeline, newest first. Filter by stage kind (open/won/lost) or by contact. For 'how are we doing' questions use pipeline_summary instead — it aggregates in the database rather than making you add up rows.pipeline_summaryreadPer-stage counts and values for every pipeline, plus what was won and lost in the last 30 days. This is the right tool for 'how is the pipeline looking' — it is one query, and the totals are the database's, not a sum you did yourself.list_tasksreadOpen tasks, soonest due first. `overdue_only` is the one to use for 'what is late'.cash_flow_forecastreadExpected money in, by month, split by how certain it is: 'invoiced' is issued and unpaid so somebody owes it, 'contracted' is a recurring schedule that will issue, and 'weighted' is open deals times their stage probability and is a guess. Do not add them together and present one number — the caller needs to know which part is a promise. An overdue invoice is counted in the current month, because that is when it can still be collected.receivables_ageingreadUnpaid invoices bucketed by how far past due they are: not yet due, 1-30, 31-60, 61-90 and 90+ days. The last bucket is the one that decides whether to keep asking or write it off.sales_healthreadHow the pipeline is performing over a window of closed deals, plus recurring revenue normalised to a month so weekly and annual retainers compare. Use this for 'how are we doing' rather than listing deals and adding them up.stalled_dealsreadOpen deals sitting in one stage longer than that stage's own median. Compared per stage rather than against a fixed number of days, because a week in an early stage is normal and a week in a late one is not. `median_days` is null where the stage has no history to judge by yet.create_contactwriteAdd a person. Search first — an email address may only belong to one live contact, and creating a duplicate is refused rather than merged. At least one of first_name, last_name or email is required.update_contactwriteChange fields on an existing contact. Only the fields you pass are touched, so this cannot blank out a phone number by not mentioning it. Use it to correct details or to move someone from lead to customer.create_dealwriteOpen a deal in a pipeline. Call pipeline_summary first to see the pipelines and their first stage; without a status_id the deal starts in the pipeline's first open stage.move_dealwriteChange a deal's stage. This is a real pipeline event, not an edit: it writes the stage history the reports read, starts any automation waiting on that stage, creates the stage's playbook tasks, and notifies the owner when the deal closes. A stage may require fields (value, expected close date, contact, company, custom fields); a move without them is refused with the missing ones named. Moving to a lost stage without a reason is allowed but unhelpful.create_taskwriteAdd a follow-up. Attach it to a contact, company or deal by passing both entity_type and entity_id, so it shows on that record rather than only in the task list.log_notewriteAppend to a record's history — a call summary, what was agreed, why a deal stalled. This is how a conversation held elsewhere ends up where the next person will look for it.list_record_typesreadThe record types this company has defined for itself — things that are not a contact, a company or a deal: properties, serviced machines, vehicles, contracts. Call this first: the `key` it returns is what list_records and create_record expect, and the field list tells you what a record of that type actually holds.list_recordsreadRecords of one custom type, newest first. `type` is the key from list_record_types. Optionally filter by a title fragment, or by the contact, company or deal a record is attached to.create_recordwriteFiles a new record of a custom type. `type` is the key from list_record_types, and `custom` takes that type's field keys — anything not defined on the type is ignored rather than stored, so check the field list first. A multiselect field takes an array of its listed options, and every element must be one of them; formula and rollup fields are worked out by the CRM and cannot be set. Links to a contact, company or deal are optional and must already exist.list_sitesreadThe public websites this company has built, with how many pages each has and which domain serves it. Call this first: `key` is what list_site_pages and create_site_page expect. A site that is not published serves only its preview URL.list_site_pagesreadEvery page of one site, with its path, whether it is published, and the section types it is built from. `path` is empty for the home page. A page with `template` set ('product' or 'category') is the layout every product or category page is built from: it has no public address of its own, and its product_detail / collection_header sections are filled in per product or category.list_site_postsreadEvery blog post of one site, newest first, with its id, title, tags and whether it is live — published and its date come. A posts section with `source: "picked"` takes `postIds` from here; one that is not live is skipped on the page, so pick live ones.create_site_pagewriteWrites a new page. `sections` is a list of {type, data} — call list_section_types for what each type accepts, including how a posts or products section chooses what it lists (`source`: latest/tag/picked, or all/category/picked with `postIds` / `productIds`). Created as a draft unless `publish` is true, because a page nobody has read should not appear on a live domain. A path already in use is refused rather than overwritten.list_section_typesreadEvery section create_site_page accepts, with the fields each one reads. Call this before building a page: a section type that does not exist is dropped, and a field nobody reads is stored and never rendered.list_quotesreadQuotes, newest first. Filter by status (draft, sent, accepted, rejected, expired, cancelled) or by the contact or company they are for. Totals are gross and in the quote's own currency.list_invoicesreadInvoices, newest first. Filter by status — `overdue` is the one to ask for when somebody wants to know who owes money, and `paid_amount` beside `total` says how much of each is still outstanding.list_productsreadThe catalogue this company sells from, with unit prices and VAT rates. `unit_price` is net; the VAT rate is a percentage on top of it. `stock` is null when a product is not stock-tracked; filter `stock` by out, low, ok or untracked to find what needs reordering.list_ordersreadOrders from the company's own shop and connected webshops, newest first. `fulfilment` is where it is in delivery (new, confirmed, shipped, delivered, cancelled); `total` is gross in the order's currency; `items` is what the customer saw.
Schemas
ContactInput{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "first_name": { "type": "string", "maxLength": 80 }, "last_name": { "type": "string", "maxLength": 80 }, "email": { "anyOf": [ { "type": "string", "maxLength": 200, "format": "email", "pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$" }, { "type": "null" } ] }, "phone": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "mobile": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "position": { "anyOf": [ { "type": "string", "maxLength": 120 }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "status": { "type": "string", "enum": [ "lead", "prospect", "customer", "inactive" ] }, "source": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "city": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "postal_code": { "anyOf": [ { "type": "string", "maxLength": 20 }, { "type": "null" } ] }, "address": { "anyOf": [ { "type": "string", "maxLength": 200 }, { "type": "null" } ] }, "notes": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "subscribed": { "type": "boolean" }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } } }CompanyCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "name": { "type": "string", "minLength": 1, "maxLength": 200 }, "domain": { "anyOf": [ { "type": "string", "maxLength": 120 }, { "type": "null" } ] }, "email": { "anyOf": [ { "type": "string", "maxLength": 200, "format": "email", "pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$" }, { "type": "null" } ] }, "phone": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "website": { "anyOf": [ { "type": "string", "maxLength": 200 }, { "type": "null" } ] }, "vat_number": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "reg_number": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "industry": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "size": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "postal_code": { "anyOf": [ { "type": "string", "maxLength": 20 }, { "type": "null" } ] }, "city": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "address": { "anyOf": [ { "type": "string", "maxLength": 200 }, { "type": "null" } ] }, "country": { "anyOf": [ { "type": "string", "minLength": 2, "maxLength": 2 }, { "type": "null" } ] }, "notes": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } }, "required": [ "name" ] }CompanyPatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "name": { "type": "string", "minLength": 1, "maxLength": 200 }, "domain": { "anyOf": [ { "type": "string", "maxLength": 120 }, { "type": "null" } ] }, "email": { "anyOf": [ { "type": "string", "maxLength": 200, "format": "email", "pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$" }, { "type": "null" } ] }, "phone": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "website": { "anyOf": [ { "type": "string", "maxLength": 200 }, { "type": "null" } ] }, "vat_number": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "reg_number": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "industry": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "size": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "postal_code": { "anyOf": [ { "type": "string", "maxLength": 20 }, { "type": "null" } ] }, "city": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "address": { "anyOf": [ { "type": "string", "maxLength": 200 }, { "type": "null" } ] }, "country": { "anyOf": [ { "type": "string", "minLength": 2, "maxLength": 2 }, { "type": "null" } ] }, "notes": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } } }DealCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "value": { "type": "number", "minimum": 0 }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "source": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "expected_close_date": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} }, "pipeline_id": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, "status_id": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" } }, "required": [ "title" ] }DealPatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "value": { "type": "number", "minimum": 0 }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "source": { "anyOf": [ { "type": "string", "maxLength": 40 }, { "type": "null" } ] }, "expected_close_date": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } } }DealStatus{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "status_id": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, "lost_reason": { "anyOf": [ { "type": "string", "maxLength": 500 }, { "type": "null" } ] } }, "required": [ "status_id" ] }TaskCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "type": { "type": "string", "enum": [ "todo", "call", "email", "meeting", "deadline" ] }, "priority": { "type": "string", "enum": [ "low", "normal", "high", "urgent" ] }, "due_at": { "type": [ "string", "null" ] }, "remind_at": { "type": [ "string", "null" ] }, "assignee_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "entity_type": { "anyOf": [ { "type": "string", "enum": [ "contact", "company", "deal" ] }, { "type": "null" } ] }, "entity_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] } }, "required": [ "title" ] }TaskPatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "type": { "type": "string", "enum": [ "todo", "call", "email", "meeting", "deadline" ] }, "priority": { "type": "string", "enum": [ "low", "normal", "high", "urgent" ] }, "due_at": { "type": [ "string", "null" ] }, "remind_at": { "type": [ "string", "null" ] }, "assignee_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "entity_type": { "anyOf": [ { "type": "string", "enum": [ "contact", "company", "deal" ] }, { "type": "null" } ] }, "entity_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] } } }QuoteCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "issue_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "valid_until": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "terms": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "items": { "minItems": 1, "maxItems": 200, "type": "array", "items": { "type": "object", "properties": { "product_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 300 }, "description": { "anyOf": [ { "type": "string", "maxLength": 1000 }, { "type": "null" } ] }, "quantity": { "type": "number", "minimum": 0 }, "unit": { "default": "db", "type": "string", "maxLength": 20 }, "unit_price": { "type": "number" }, "discount_pct": { "default": 0, "type": "number", "minimum": 0, "maximum": 100 }, "vat_rate": { "default": 27, "type": "number", "minimum": 0, "maximum": 100 }, "vat_reason": { "anyOf": [ { "type": "string", "enum": [ "AAM", "TAM", "KBAET", "EUFAD37", "FAD", "HO", "EAM" ] }, { "type": "null" } ] } }, "required": [ "name", "quantity" ] } } }, "required": [ "items" ] }ProductCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "sku": { "anyOf": [ { "type": "string", "maxLength": 60 }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 2000 }, { "type": "null" } ] }, "unit": { "type": "string", "maxLength": 20 }, "unit_price": { "type": "number", "minimum": 0 }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "vat_rate": { "type": "number", "minimum": 0, "maximum": 100 }, "category": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "active": { "type": "boolean" } }, "required": [ "name" ] }ProductPatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "sku": { "anyOf": [ { "type": "string", "maxLength": 60 }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 200 }, "description": { "anyOf": [ { "type": "string", "maxLength": 2000 }, { "type": "null" } ] }, "unit": { "type": "string", "maxLength": 20 }, "unit_price": { "type": "number", "minimum": 0 }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "vat_rate": { "type": "number", "minimum": 0, "maximum": 100 }, "category": { "anyOf": [ { "type": "string", "maxLength": 80 }, { "type": "null" } ] }, "active": { "type": "boolean" } } }StockMove{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "delta": { "type": "integer", "minimum": -9007199254740991, "maximum": 9007199254740991 }, "count": { "anyOf": [ { "type": "integer", "minimum": 0, "maximum": 9007199254740991 }, { "type": "null" } ] }, "reason": { "type": "string", "enum": [ "restock", "adjust", "return" ] }, "note": { "type": "string", "maxLength": 500 } } }RecordCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "type": { "type": "string", "minLength": 1, "maxLength": 40 }, "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } }, "required": [ "type", "title" ] }RecordPatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "title": { "type": "string", "minLength": 1, "maxLength": 200 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 5000 }, { "type": "null" } ] }, "owner_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "custom": { "type": "object", "propertyNames": { "type": "string" }, "additionalProperties": {} } } }HookCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "event": { "type": "string", "enum": [ "contact.created", "contact.updated", "deal.created", "deal.status_changed", "deal.won", "deal.lost", "quote.accepted", "quote.rejected", "invoice.paid", "form.submitted", "task.completed", "webshop.order", "record.created", "record.updated", "company.created", "company.updated", "deal.updated", "task.created", "quote.created", "product.created", "product.updated", "invoice.issued", "lead.received", "call.ended", "call.missed" ] }, "target_url": { "type": "string", "maxLength": 500, "format": "uri" } }, "required": [ "event", "target_url" ] }QuotePatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "issue_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "valid_until": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "terms": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "items": { "minItems": 1, "maxItems": 200, "type": "array", "items": { "type": "object", "properties": { "product_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 300 }, "description": { "anyOf": [ { "type": "string", "maxLength": 1000 }, { "type": "null" } ] }, "quantity": { "type": "number", "minimum": 0 }, "unit": { "default": "db", "type": "string", "maxLength": 20 }, "unit_price": { "type": "number" }, "discount_pct": { "default": 0, "type": "number", "minimum": 0, "maximum": 100 }, "vat_rate": { "default": 27, "type": "number", "minimum": 0, "maximum": 100 }, "vat_reason": { "anyOf": [ { "type": "string", "enum": [ "AAM", "TAM", "KBAET", "EUFAD37", "FAD", "HO", "EAM" ] }, { "type": "null" } ] } }, "required": [ "name", "quantity" ] } } } }InvoiceCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "kind": { "type": "string", "enum": [ "normal", "proforma", "advance" ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "issue_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "fulfillment_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "due_date": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "payment_method": { "type": "string", "enum": [ "transfer", "cash", "card" ] }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "vat_exemption": { "anyOf": [ { "type": "string", "enum": [ "EUFAD37", "KBAET", "HO", "EAM" ] }, { "type": "null" } ] }, "deduct_advances": { "maxItems": 20, "type": "array", "items": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" } }, "items": { "minItems": 1, "maxItems": 200, "type": "array", "items": { "type": "object", "properties": { "product_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 300 }, "description": { "anyOf": [ { "type": "string", "maxLength": 1000 }, { "type": "null" } ] }, "quantity": { "type": "number", "minimum": 0 }, "unit": { "default": "db", "type": "string", "maxLength": 20 }, "unit_price": { "type": "number" }, "discount_pct": { "default": 0, "type": "number", "minimum": 0, "maximum": 100 }, "vat_rate": { "default": 27, "type": "number", "minimum": 0, "maximum": 100 }, "vat_reason": { "anyOf": [ { "type": "string", "enum": [ "AAM", "TAM", "KBAET", "EUFAD37", "FAD", "HO", "EAM" ] }, { "type": "null" } ] } }, "required": [ "name", "quantity" ] } } }, "required": [ "items" ] }InvoicePatch{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "kind": { "type": "string", "enum": [ "normal", "proforma", "advance" ] }, "contact_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "company_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "deal_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "issue_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "fulfillment_date": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "due_date": { "anyOf": [ { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, { "type": "null" } ] }, "payment_method": { "type": "string", "enum": [ "transfer", "cash", "card" ] }, "currency": { "type": "string", "minLength": 3, "maxLength": 3 }, "notes": { "anyOf": [ { "type": "string", "maxLength": 6000 }, { "type": "null" } ] }, "vat_exemption": { "anyOf": [ { "type": "string", "enum": [ "EUFAD37", "KBAET", "HO", "EAM" ] }, { "type": "null" } ] }, "deduct_advances": { "maxItems": 20, "type": "array", "items": { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" } }, "items": { "minItems": 1, "maxItems": 200, "type": "array", "items": { "type": "object", "properties": { "product_id": { "anyOf": [ { "type": "string", "format": "uuid", "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$" }, { "type": "null" } ] }, "name": { "type": "string", "minLength": 1, "maxLength": 300 }, "description": { "anyOf": [ { "type": "string", "maxLength": 1000 }, { "type": "null" } ] }, "quantity": { "type": "number", "minimum": 0 }, "unit": { "default": "db", "type": "string", "maxLength": 20 }, "unit_price": { "type": "number" }, "discount_pct": { "default": 0, "type": "number", "minimum": 0, "maximum": 100 }, "vat_rate": { "default": 27, "type": "number", "minimum": 0, "maximum": 100 }, "vat_reason": { "anyOf": [ { "type": "string", "enum": [ "AAM", "TAM", "KBAET", "EUFAD37", "FAD", "HO", "EAM" ] }, { "type": "null" } ] } }, "required": [ "name", "quantity" ] } } } }InvoiceIssue{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "exchange_rate": { "type": "number", "exclusiveMinimum": 0 } } }PaymentCreate{ "$schema": "https://json-schema.org/draft/2020-12/schema", "type": "object", "properties": { "amount": { "type": "number", "exclusiveMinimum": 0 }, "paid_on": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$" }, "method": { "type": "string", "enum": [ "transfer", "cash", "card", "other" ] }, "note": { "type": "string", "maxLength": 300 } }, "required": [ "amount" ] }Error{ "type": "object", "properties": { "error": { "type": "string", "enum": [ "missing_bearer_token", "invalid_api_key", "expired_api_key", "missing_scope:write", "plan_refused", "not_found", "idempotency_in_progress", "email_already_exists", "validation_failed", "no_fields_to_update", "rate_limited", "missing_scope:quotes:write", "missing_scope:invoices:write", "not_draft", "not_payable", "not_issuable", "invalid_target_url", "too_many_hooks", "unknown_event" ] }, "detail": { "description": "Optional; validation issues or a plan code." }, "retry_after": { "type": "integer", "description": "Seconds, on a 429." } }, "required": [ "error" ] }Pagination{ "type": "object", "properties": { "limit": { "type": "integer" }, "offset": { "type": "integer" }, "total": { "type": "integer" } } }