Payment Request Routing Preview
GET/api/vendor-deposits/payment-request-routing
Preview where a payment request would route before submitting. Drives the "Payment request will be sent to …" indicator in the Record Proforma Invoice drawer and the draft-deposit hint.
accounting:readGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Routing precedence: matching approval levels → the site-wide default payer (AccountingSettings.vendor_deposit_default_payer_user_id, set in Accounting Settings) → the legacy amount threshold.
Response fields:
mode—approval_levels|payer|self_payer|threshold_approval|auto_approvepayer—{id, name, email}of the resolved site-wide payer, or nullpayer_configured— true when a payer id is configured even if unresolvable (admins are notified in that case)levels_count— matching approval levels when mode=approval_levels
auto_approve means nothing is configured: submitting will auto-approve without notifying anyone — the UI warns and links to Accounting Settings.
self_payer means the acting user is themselves the configured payer: there is no one to send a request to, so submitting approves the deposit immediately and the payment can be recorded directly.
Request
Responses
- 200
- 401
- 403
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.