billing

POST /v1/accounting/xero/sync

Push outstanding invoices to Xero now.

Alle billing Endpunkte

Authentifizierung

Senden Sie einen API-Schlüssel als Bearer-Token. Der Schlüssel muss über die Berechtigung billing.invoice.manage verfügen; ein Schlüssel ohne diese wird mit 403 statt 404 abgelehnt.

Dieser Endpunkt erfordert keine Organisations-ID. Ihr Schlüssel identifiziert bereits die zugehörige Organisation, und die Antwort ist entsprechend eingeschränkt.

Ausprobieren

Ersetzen Sie alles in spitzen Klammern durch Ihre eigenen Werte und den Platzhalter für den Schlüssel durch einen Schlüssel aus Ihrem Dashboard.

curl -X POST https://api.zinndigital.com/v1/accounting/xero/sync \
  -H "Authorization: Bearer zdk_live_…"

Angemeldet? Die API-Konsole in Ihrem Dashboard trägt automatisch Ihre echte Organisations-ID sowie Ihren eigenen Schlüssel ein und führt die Anfrage gegen die Live-API aus, sodass Sie die tatsächliche Antwort sehen können. Öffnen Sie diesen Endpunkt in der API-Konsole

Details

Runs a batch immediately instead of waiting for the hourly sweep. Idempotent: every invoice carries a deterministic reference and the engine searches Xero for it before creating anything, so pressing this twice cannot produce two invoices in the customer's books. `409` means the connection needs reconnecting. Nothing is lost in that state — outstanding invoices stay queued and are sent on reconnect. Requires `billing.invoice.manage`.

Antwort

NameTypErforderlichWas es ist
pushedintegerJa
failedintegerJa
remainingintegerJaStill outstanding after this batch. ⛔ Reported so a client never infers "finished" from a short batch — some rows may have failed rather than completed.
connectionXeroConnectionNeinAn organization's link to its own Xero. ⛔ `needs_reconnect` is a distinct state from `not_connected` on purpose — see `getMyXeroConnection`.

Fehler, die dieser Endpunkt zurückgeben kann

401 · 403 · 404 · 409 · 429