cancel
POST
/v1/payments/{paymentCode}/cancel
const url = 'https://api.lydiagate.com/v1/payments/example/cancel';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.lydiagate.com/v1/payments/example/cancel \ --header 'Authorization: Bearer <token>'Authorizations
Bölüm başlığı “Authorizations”Parameters
Bölüm başlığı “Parameters”Path Parameters
Bölüm başlığı “Path Parameters”paymentCode
required
string
Responses
Bölüm başlığı “Responses”İptal edildi ya da zaten iptal edilmişti (idempotentReplay=true). Bazı banka bağlantılarında iptal bankada sürerken yanıt status: "awaiting_capture" döner; ödeme bankanın teyidinden sonra cancelled olur.
Media typeapplication/json
object
paymentCode
string
status
string
idempotentReplay
boolean
Example
{ "status": "initiated"}Partner CLOSED — partner_not_active.
Media type*/*
object
paymentCode
string
status
string
idempotentReplay
boolean
Ödeme yok ya da başka partnerin — payment_not_found.
Media type*/*
object
paymentCode
string
status
string
idempotentReplay
boolean
Ödeme iptal edilebilir durumda değil (captured, expired, …) — payment_not_cancellable.
Media type*/*
object
paymentCode
string
status
string
idempotentReplay
boolean
Ödeme auto modda — capture_mode_mismatch.
Media type*/*
object
paymentCode
string
status
string
idempotentReplay
boolean