pencilCreate refund

Create Refund

post

Allows for the creation of a full or partial refund for a previously completed deposit.

  • For credit card deposits, the refund is processed to the same card, requiring only deposit identification.

  • For other payment methods, beneficiary bank account details are necessary.

  • Multiple partial refunds can be issued for a single deposit, provided the total refunded amount does not exceed the original deposit amount.

Header parameters
Content-TypestringRequired

Media type of the body sent to the API.

Default: application/json
X-Datestring · date-timeRequired

ISO8601 Datetime with Timezone (e.g., 2023-05-27T10:00:00Z).

X-LoginstringRequired

Merchant X-Login API Key.

AuthorizationstringRequired

Authorization control hash, calculated as explained in the onekeypayments documentation.

X-Idempotency-KeystringOptional

Unique idempotency key to prevent duplicate processing of the same request.

Body
deposit_idintegerRequired

onekeypayments deposit_id. It is obtained when creating the deposit. Must be a valid deposit_id of a completed deposit.

Example: 300533646
invoice_idstring · max: 128Required

The invoice_id you sent while creating the deposit or the merchant_invoice_id auto-generated by onekeypayments. Must be a valid invoice_id of a completed deposit.

Example: newIUnit45328731
amountnumber · doubleOptional

Amount to refund. Positive, up to 2 decimal places. Must be equal to or smaller than the deposit amount. If not sent, a full refund is assumed.

Example: 100
commentsstring · max: 200Optional

Optional comments about the refund.

Example: Test refund over v3
notification_urlstring · uri · max: 2048Optional

Valid HTTPS URL (URI) used to send asynchronous notifications about the refund's status changes.

Example: https://webhook.site/url
Responses
post
/v3/refunds

Last updated

Was this helpful?