Payout Bulk Actions
Performs batch operations on multiple payouts to mark them as paid or unpaid.
Last updated: April 9, 2026
Payout Bulk Actions
POST /siren/v1/payouts/bulk
Performs an action on multiple payouts at once.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
action | string | Yes | One of: markPaid, markUnpaid |
ids | integer[] | Yes | Array of payout IDs to act upon |
Action Behaviors
| Action | Effect | Events |
|---|---|---|
markPaid | Sets status to paid, sets datePaid to current timestamp | Broadcasts PayoutPaid per record |
markUnpaid | Sets status to unpaid, clears datePaid to null | — |
Payouts already in the target status are skipped. Non-existent IDs are silently skipped.
Example
{
"action": "markPaid",
"ids": [20, 21]
}
{
"success": true,
"affected": 2
}
State Transition Rules
Payout status is a simple toggle between paid and unpaid. The datePaid timestamp is set when marking as paid and cleared when marking as unpaid. Both the bulk action endpoint and the export endpoint (when markAsPaid is true) use the same underlying mechanism to transition payout status and broadcast events.