Dispatch a payable to the bank
POST/payables/:id/send-to-bank
Dispatches an approved payable to the bank through the Kobana gateway (creates the payment, then envelopes and approves it on the gateway side). Requires scope finance.payables.dispatch — deliberately separate from finance.payables.write (dispatching money is not editing a bill). X-Idempotency-Key is required. Only an official bill dispatches — one whose payment_approval is null or creation_approved; a bill still awaiting approval (pending_approval / partially_approved) or creation_rejected returns 422. The payable must also carry the payment coordinates for its method and a Kobana-mirrored source account. Returns the refreshed payable detail with the execution mirror (kobana_status, kobana_payment_uid) populated. Note: the Kobana sandbox example_bank does not execute outbound payments, so the full confirmed cycle is only observable against an environment that actually settles.
Request
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 422
- 429
- 500
Dispatched. Body is the refreshed payable detail with the Kobana mirror populated.
Missing / blank X-Idempotency-Key.
Missing / invalid / expired / revoked token.
Token lacks the finance.payables.dispatch scope.
Payable not found within the tenant.
X-Idempotency-Key reused with a different body.
Not dispatchable: bill not official (awaiting approval / rejected), missing payment coordinates, source account not mirrored in Kobana, or the Kobana integration is not connected.
Rate limit exceeded for this token. Reads and writes have separate budgets, both on a 1-hour sliding window. The response carries X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset and Retry-After — wait out Retry-After rather than retrying immediately.
Unhandled server error.