Skip to navigation

Get Intent

View as Markdown

Get a payment intent by ID.

Supports expand parameter:

  • expand=checkout_attempt: Include full checkout attempt details (checkout attempt, card checkout attempt, processor attempts, state transitions)

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

external_idstringRequired
account_idstringRequired

Query parameters

expandlist of strings or nullOptional

Response

Successful Response
idstring
account_idstring
customer_idstring
amount_atominteger
currencyenum
ISO 4217 currency codes.
statusstring
client_secretstring or null
confirmed_atdatetime or null
metadatamap from strings to any or null
created_atdatetime
updated_atdatetime
display_statusstringOptionalDefaults to

Merchant-facing status label derived from internal state + creation context. Render this in UIs — never the raw status. A settled refund replaces it with “Refunded”, “Partially refunded” or “Refunded out-of-band” on API reads; payment_intent.* webhooks carry no refund totals and keep the payment’s own status.

tooltip_keystring or nullOptional

Explicit key the frontend maps to tooltip copy (Decision Q4). None where no tooltip is shown (SUCCEEDED, EXCEPTION, the refund statuses).

refund_statusenum or nullOptional

The refund status display_status shows once a refund settled (refunded, partially_refunded, refunded_out_of_band); null without one. A key to branch on rather than the display copy. The refunded total includes chargebacks, so a charged-back payment reads refunded.

Allowed values:
created_viastring or nullOptional

Write-once provenance: how this payment intent was created (checkout, checkout_setup, invoice, api, migration).

cancellation_reasonstring or nullOptional

Why a cancelled payment intent was cancelled (hold_released, expired, payment_cancelled). None unless the intent was cancelled.

amount_atom_capturableintegerOptionalDefaults to 0
amount_atom_receivedintegerOptionalDefaults to 0
amount_atom_refundedintegerOptionalDefaults to 0
Total refunded amount
amount_atom_refund_pendingintegerOptionalDefaults to 0

Total amount of refunds that are in progress (requested but not yet settled by the processor — RefundStatus pending/requires_action). amount_atom_refunded only moves once a refund settles, which can take 30+ minutes; this exposes the in-flight amount so the UI can show a ‘Refund in progress’ indicator in the meantime.

refunded_atdatetime or nullOptional

When the latest successful refund happened (None if never refunded)

refunded_out_of_bandbooleanOptionalDefaults to false

Whether any succeeded refund on this payment was recorded out-of-band — refunded on the processor’s own dashboard rather than through PaymentKit. Only surfaces to merchants when the payment is FULLY refunded, where the status reads ‘Refunded out-of-band’ instead of ‘Refunded’.

attempt_countinteger or nullOptionalDefaults to 0
Number of processor attempts
invoiceslist of objectsOptional
customer_emailstring or nullOptional
Customer email address
payment_methodobject or nullOptional

Payment method used (from latest attempt)

processorobject or nullOptional

Payment processor used (from latest attempt)

decline_reasonstring or nullOptional
Decline reason from latest failed attempt
failure_codestring or nullOptional

Machine-readable failure code from the latest failed attempt (e.g. ‘currency_unsupported’). Lets the UI render a specific, localizable reason. None when no coded failure is available.

binstring or nullOptional

Card BIN/IIN — the issuer prefix of the card number, 6 or 8 digits depending on the network. Sourced from the card itself, so it is the same value for a given card regardless of which processor handled the payment, and is present on declined payments too. Exposed for CSV export; not shown in the in-app payments table. None for non-card methods, or for cards saved before this data was captured.

is_merchant_initiatedboolean or nullOptional

Whether this is a merchant-initiated transaction (MIT). False = customer-initiated (CIT). None = unknown/legacy.

attempted_payment_method_typeenum or nullOptional

The payment method type the buyer chose at checkout when no payment method was saved. Populated today for the BNPL providers only (klarna, afterpay, affirm): their PaymentMethod is created once the provider approves, so a cancelled or declined BNPL checkout has payment_method null but this set, and a list can still show which method was tried. None whenever payment_method is present, and for card and wallet checkouts.

checkout_attemptobject or nullOptional
Expanded checkout attempt data for payment intent detail view.

Errors

422
Unprocessable Entity Error