v1

latestOpenAPI 3.1.02026-07-241642423.7 KB

Cancel a payment

post/payments/{payment}/cancel

Path parameters

paymentstring required

Response

200

idstring
statusstring
amountstring
typestring
parent_typestring
parent_idstring
can_retryboolean
can_refundboolean
can_cancelboolean
cancel_deadlinestring
directionstring

Example response

{
  "id": "pyt_vIFHhvyGN47ej1upyIT8",
  "status": "failed",
  "amount": "4522.0400",
  "type": "employee_net_pay",
  "parent_type": "payroll_item",
  "parent_id": "pyi_ENA4k8LMHbgpV07GLGSv",
  "payment_attempts": [
    {
      "id": "pya_Kgl6ERboridVSfv4XKdT",
      "created_at": "2022-02-18T20:14:40.713837Z",
      "expected_completion_date": "2022-02-23",
      "status": "canceled",
      "payment_method": "ach",
      "payment_instrument": "bnk_W7hjDGn6sU1d3U8dr9bq"
    }
  ],
  "cancel_deadline": "2022-02-19T17:00:00.000Z",
  "direction": "credit"
}