ASTRO_PAY_QR

AstroPayQrPayload

Payment Method Identifier

ASTRO_PAY_QR

Description

This method allows you to accept AstroPay QR payments. Customers scan a dynamically generated QR code using the AstroPay mobile app to complete the payment instantly.

Currency Support

Supports currencies available on the AstroPay platform. Refer to your merchant configuration for the specific currencies enabled on your account.

✅ Required Request Fields

Top-Level Fields

FieldTypeDescription
callbackUrlStringURL to receive transaction status updates
successRedirectUrlStringURL to redirect the customer after successful payment
failureRedirectUrlStringURL to redirect the customer after failed payment

Billing Details (ApmBillingDetails)

FieldTypeDescription
firstNameStringCustomer's first name
lastNameStringCustomer's last name
address1StringFirst line of the billing address
cityStringCity of the billing address
countryStringCountry code in ISO Alpha-2 format
postalCodeStringPostal/ZIP code
phoneStringCustomer's phone number
emailStringCustomer's email address

Device Information (Device)

FieldTypeDescription
ipStringCustomer's IP address

Payload Structure

{
  "paymentMethod": "ASTRO_PAY_QR",
  "paymentType": "E_WALLET"
}

Fields

FieldTypeRequiredDescription
paymentMethodEnumYesMust be "ASTRO_PAY_QR"
paymentTypeEnumYesMust be "E_WALLET"

No additional fields are required. All necessary user interaction is handled within the AstroPay mobile app.

Expected apmResponseData (AstroPayQrResponseData)

{
  "paymentMethod": "ASTRO_PAY_QR",
  "paymentType": "E_WALLET",
  "redirectUrl": null,
  "iframeUrl": null,
  "providerTransactionId": "payment-code-external-id",
  "actionType": "QR",
  "qrData": "data:image/png;base64,iVBORw0KGgoAAAA...CYII=",
  "qrDeepLink": null
}

Response Fields

FieldTypeDescription
paymentMethodEnum"ASTRO_PAY_QR"
paymentTypeEnum"E_WALLET"
redirectUrlString (nullable)Always null for ASTRO_PAY_QR
iframeUrlString (nullable)Always null for ASTRO_PAY_QR
providerTransactionIdString (nullable)Transaction ID from AstroPay
actionTypeStringAlways "QR"
qrDataString (nullable)QR code image encoded as a base64 data URI (data:image/png;base64,...). Can be used directly in an <img> tag: <img src="$qrData" width="200" height="200" alt="QR Code">
qrDeepLinkString (nullable)Deep link URL to open the AstroPay app directly on mobile devices. May be null if not provided by the payment provider.


Deep link URL to open the AstroPay app directly on mobile devices. May be null if not provided by the payment provider.