Home
Home
  1. Payment Requests
  • Welcome
    • About Ontime
    • Overview
    • Test and Learn Projects
  • Authentication
  • Availability Check
    • Light Availability Check
      POST
    • Full Availability Check
      POST
  • Payment Management
    • Mandates
      • Create a new mandate
      • Cancel an existing mandate
      • Get a Mandate
      • Get many Mandates
    • Payment Requests
      • Instruct a new payment request
        POST
      • Cancel an existing payment request
        DELETE
      • Get a Payment
        GET
      • Get many Payments
        GET
  • Payouts
    • Get a Payout
      GET
    • Get Available Payouts
      GET
  • Webhooks
    • Mandate Created/Updated
    • Payment Request Created/Updated
    • Payout Created
  1. Payment Requests

Cancel an existing payment request

Developing
Cloud Mock
https://mock.apidog.com/m1/828215-0-default
Cloud Mock
https://mock.apidog.com/m1/828215-0-default
DELETE
https://mock.apidog.com/m1/828215-0-default
/payments/{payment_id}
OperationId:cancel_payment_request_by_id
This will attempt to cancel a previously requested payment. The operation will fail if the payment is already in the process of being deducted by the payroll.

Request

Authorization
API Key
Add parameter in header
x-api-key
Example:
x-api-key: ********************
OAuth 2.0
Client Credentials
Add the parameter
Authorization
to Headers
,whose value is to concatenate the Token after the Bearer.
Example:
Authorization: Bearer ********************
Token URL: https://{domain}.auth.{region}.amazoncognito.com
Scopes:
payments:write-Create and cancel payment requests.
or
Path Params

Responses

🟢200Success
application/json
Body

🟠409Conflict
🟠422Parameter Error
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request DELETE 'https://mock.apidog.com/m1/828215-0-default/payments/ce8c38b9-8fc0-4c34-a0a0-1ec929271b58' \
--header 'x-api-key: <api-key>' \
--header 'Authorization: Bearer <token>'
Response Response Example
200 - Example 1
{
    "payment_record": {
        "id": "4e5faa78-3eb5-4fde-a252-7c81fcf51fcd",
        "mandate_id": "4a60bedd-e1ca-4104-ad4f-8f6c0f39cac3",
        "due_date": "2025-08-11T14:50:50.131Z",
        "requested_amount": 27593,
        "currency": "XPF",
        "expected_pay_date": "2025-08-04T14:50:50.131Z",
        "status": "Submitted",
        "actual_amount": 45324,
        "metadata": null
    }
}
Previous
Instruct a new payment request
Next
Get a Payment