Payments - Submit Eligibility Data
POST /payments/{payment_id}/eligibility
Submit eligibility data for a payment (used for 3DS/browser info, card details, etc.).
Example (cURL)
curl --request POST \
--url https://sandbox.hyperswitch.io/payments/{payment_id}/eligibility \
--header 'Content-Type: application/json' \
--header 'api-key: <api-key>' \
--data '
{
"client_secret": "pay_U42c409qyHwOkWo3vK60_secret_el9ksDkiB8hi6j9N78yo",
"payment_method_type": "card",
"payment_method_data": {
"card": {
"card_number": "4242424242424242",
"card_exp_month": "24",
"card_exp_year": "24",
"card_holder_name": "John Test",
"card_cvc": "242",
"card_issuer": "chase",
"card_network": "Visa",
"card_type": "CREDIT",
"card_issuing_country": "INDIA",
"card_issuing_country_code": "IN",
"bank_code": "JP_AMEX",
"nick_name": "John Test"
},
"billing": {
"address": {
"city": "New York",
"country": "AF",
"line1": "123, King Street",
"line2": "Powelson Avenue",
"line3": "Bridgewater",
"zip": "08807",
"state": "New York",
"first_name": "John",
"last_name": "Doe",
"origin_zip": "08807"
},
"phone": {
"number": "9123456789",
"country_code": "+1"
},
"email": "<string>"
}
},
"payment_method_subtype": "ach",
"browser_info": {
"color_depth": 1,
"java_enabled": true,
"java_script_enabled": true,
"language": "<string>",
"screen_height": 1,
"screen_width": 1,
"time_zone": 123,
"ip_address": "<string>",
"accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",
"user_agent": "<string>",
"os_type": "<string>",
"os_version": "<string>",
"device_model": "<string>",
"accept_language": "<string>",
"referer": "<string>"
}
}
'Responses
200 — Eligibility submit is successful
Example response:
400 — Bad request / validation error
Authorizations
Header: api-key (string, required)
Publishable keys are a type of keys that can be public and have limited scope of usage.
Path parameters
payment_id (string, required) — The identifier for payment
Body (application/json)
client_secret (string, required) — Token used for client side verification Example: "pay_U42c409qyHwOkWo3vK60_secret_el9ksDkiB8hi6j9N78yo"
payment_method_type (enum, required) — Indicates the type of payment method. Examples:
card,wallet, etc. Available options include: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
payment_method_data (object, required) — The payment method information provided for making a payment. Supported types (child attributes exist for each type):
Card
CardRedirect
Wallet
PayLater
BankRedirect
BankDebit
BankTransfer
RealTimePayment
Crypto
Upi
Voucher
GiftCard
CardToken
OpenBanking
MobilePayment
NetworkToken
payment_method_subtype (enum) — Indicates the sub type of payment method (e.g.,
google_pay,apple_payfor wallets). See full list below.
browser_info (object) — Browser information to be used for 3DS 2.0. Example fields:
color_depth (number)
java_enabled (boolean)
java_script_enabled (boolean)
language (string)
screen_height (number)
screen_width (number)
time_zone (number)
ip_address (string)
accept_header (string)
user_agent (string)
os_type (string)
os_version (string)
device_model (string)
accept_language (string)
referer (string)
Response fields
payment_id (string, required) — The identifier for the payment
sdk_next_action (object, required) — Next action for SDK e.g.
{ "next_action": "post_session_tokens" }
If you want to suggest edits or report an issue for this documentation, see:
Suggest edits: https://github.com/juspay/hyperswitch/edit/main/api-reference/v1/payments/payments--submit-eligibility-data.mdx
Raise issue: https://github.com/juspay/hyperswitch/issues/new?title=Issue%20on%20docs&body=Path:%20/v1/payments/payments--submit-eligibility-data