Skip to main content
POST
Revenue Recovery - Create

Authorizations

Authorization
string
header
required

Format: api-key=<api_key>

Use the API key created under your merchant account from the HyperSwitch dashboard. API key is used to authenticate API requests from your merchant server only. Don't expose this key on a website or embed it in a mobile application.

Body

application/json
amount_details
object
required
billing_merchant_connector_id
string
required

Billing connector id to update the invoices.

Example:

"mca_1234567890"

payment_merchant_connector_id
string
required

Payments connector id to update the invoices.

Example:

"mca_1234567890"

transaction_status
enum<string>
required

The status of the attempt

Available options:
started,
authentication_failed,
router_declined,
authentication_pending,
authentication_successful,
authorized,
authorization_failed,
charged,
authorizing,
cod_initiated,
voided,
voided_post_charge,
void_initiated,
capture_initiated,
capture_failed,
void_failed,
auto_refunded,
partial_charged,
partially_authorized,
partial_charged_and_chargeable,
unresolved,
pending,
failure,
payment_method_awaited,
confirmation_awaited,
device_data_collection_pending,
integrity_failure,
expired,
capture_review
payment_method_sub_type
enum<string>
required

Indicates the sub type of payment method. Eg: 'google_pay' & 'apple_pay' for wallets.

Available options:
ach,
affirm,
afterpay_clearpay,
alfamart,
ali_pay,
ali_pay_hk,
alma,
amazon_pay,
paysera,
apple_pay,
atome,
bacs,
bancontact_card,
becs,
benefit,
bizum,
blik,
bluecode,
boleto,
bca_bank_transfer,
bni_va,
breadpay,
bri_va,
bhn_card_network,
card_redirect,
cimb_va,
classic,
credit,
crypto_currency,
cashapp,
dana,
danamon_va,
debit,
duit_now,
efecty,
eft,
eft_debit_order,
eps,
flexiti,
fps,
evoucher,
giropay,
givex,
google_pay,
go_pay,
gcash,
ideal,
interac,
indomaret,
klarna,
kakao_pay,
local_bank_redirect,
mandiri_va,
knet,
mb_way,
mobile_pay,
momo,
momo_atm,
multibanco,
online_banking_thailand,
online_banking_czech_republic,
online_banking_finland,
online_banking_fpx,
online_banking_poland,
online_banking_slovakia,
oxxo,
pago_efectivo,
permata_bank_transfer,
open_banking_uk,
pay_bright,
payjustnow,
paypal,
paze,
pix,
pix_key,
pix_emv,
pix_qr,
pix_automatico_qr,
pix_automatico_push,
pay_safe_card,
przelewy24,
prompt_pay,
pse,
qris,
red_compra,
red_pagos,
samsung_pay,
sepa,
sepa_bank_transfer,
sepa_guarenteed_debit,
skrill,
sofort,
swish,
touch_n_go,
trustly,
twint,
upi_collect,
upi_intent,
upi_qr,
vipps,
viet_qr,
venmo,
walley,
we_chat_pay,
seven_eleven,
lawson,
mini_stop,
family_mart,
seicomart,
pay_easy,
local_bank_transfer,
mifinity,
open_banking_pis,
direct_carrier_billing,
instant_bank_transfer,
instant_bank_transfer_finland,
instant_bank_transfer_poland,
revolut_pay,
indonesian_bank_transfer,
open_banking,
network_token,
payshap,
payshap_proxy
connector_customer_id
string
required

customer id at payment connector for which mandate is attached.

Example:

"cust_12345"

payment_method_data
object
required
action
enum<string>
required

type of action that needs to taken after consuming recovery payload

Available options:
cancel_invoice,
schedule_failed_payment,
success_payment_external,
pending_payment,
no_action,
invalid_action
merchant_reference_id
string | null

The invoice identifier from the merchant's billing system that this payment attempt is being recorded against. This ensures idempotency when the same invoice is reported more than once.

Required string length: 30
Example:

"invoice_mbabizu24mvu3mela5njyh"

error
object | null

Error details for the payment

billing
object | null
transaction_created_at
string<date-time> | null

The time at which payment attempt was created.

Example:

"2022-09-10T10:11:12Z"

payment_method_type
enum<string> | null

Indicates the type of payment method. Eg: 'card', 'wallet', etc.

Available options:
card,
card_redirect,
pay_later,
wallet,
bank_redirect,
bank_transfer,
crypto,
bank_debit,
reward,
real_time_payment,
upi,
voucher,
gift_card,
open_banking,
mobile_payment,
network_token
billing_started_at
string<date-time> | null

Invoice billing started at billing connector end.

Example:

"2022-09-10T10:11:12Z"

connector_transaction_id
string | null

A unique identifier for a payment provided by the payment connector

Example:

"993672945374576J"

enable_partial_authorization
boolean | null
default:false

Allow partial authorization for this payment

metadata
object | null

You can specify up to 50 keys, with key names up to 40 characters long and values up to 500 characters long. Metadata is useful for storing additional, structured information on an object.

Response

Revenue Recovery Payment Recorded Successfully

id
string
required

Unique identifier for the payment.

Required string length: 30
Example:

"pay_mbabizu24mvu3mela5njyhpit4"

intent_status
enum<string>
default:requires_confirmation
required

Represents the overall status of a payment intent. The status transitions through various states depending on the payment method, confirmation, capture method, and any subsequent actions (like customer authentication or manual capture).

Available options:
succeeded,
failed,
cancelled,
cancelled_post_capture,
processing,
requires_customer_action,
requires_merchant_action,
requires_payment_method,
requires_confirmation,
requires_capture,
partially_captured,
partially_captured_and_capturable,
partially_authorized_and_requires_capture,
partially_captured_and_processing,
conflicted,
expired,
review
merchant_reference_id
string | null

Unique identifier for the payment. This ensures idempotency for multiple payments that have been done by a single merchant.

Required string length: 30
Example:

"pay_mbabizu24mvu3mela5njyhpit4"