Aller au contenu

Payments: Retrieve

La référence API est disponible en anglais uniquement.

GET/payments/{payment_id}

Retrieves a Payment. This API can also be used to get the status of a previously initiated payment or next action for an ongoing payment

Path parameters

  • payment_idstringrequired

    The identifier for payment

Query parameters

  • force_syncboolean, nullable

    Decider to enable or disable the processor call for retrieve request

  • client_secretstring, nullable

    This is a token which expires after 15 minutes, used from the client to authenticate and create sessions from the SDK

  • expand_attemptsboolean, nullable

    If enabled provides list of attempts linked to payment intent

  • expand_capturesboolean, nullable

    If enabled provides list of captures linked to latest attempt

Responses

  • 200Gets the payment with final status
  • 404No payment found

Request

curl --request GET \
  --url https://sandbox.cardencer.com/payments/{payment_id} \
  --header 'api-key: snd_...'

Response

{
  "payment_id": "pay_mbabizu24mvu3mela5njyhpit4",
  "merchant_id": "merchant_1668273825",
  "status": "requires_confirmation",
  "amount": 6540,
  "net_amount": 6540,
  "amount_capturable": 6540,
  "processor_merchant_id": "merchant_1689512302",
  "currency": "AED",
  "payment_method": "card",
  "attempt_count": 0
}