Payout orders Cancel

Cancel a payout order if is possible

Cancels a payout order that is still created, waiting_validation, waiting_approval or scheduled. On success the payout order transitions to cancelled and the resulting state is returned.

Those four are the only states the transition is allowed from. An order that is already approved, pending_funds, enqueued or executing cannot be cancelled even though it has not finished, and neither can one in a terminal state. In every one of those cases the request fails with 422 and the payout order is left untouched.

patch/payout_orders/{payout_order_id}/state/cancel

Request

  • Base URL
    https://api.treasury.shinkansen.finance/v1
  • URL
    https://api.treasury.shinkansen.finance/v1/payout_orders/{payout_order_id}/state/cancel
  • Auth
    API key in header Shinkansen-Treasury-Api-Key

Response

Returns when was possible to cancel the payout order identified by the given id.

shinkansen_payout_order_statestring

The state of the payout order. This will have the value "cancelled" as other values return error.

Example response

{
  "shinkansen_payout_order_state": "cancelled"
}

Changes

No recorded changes to this operation across all 1 revision of this API.