Apple Pay on Hosted Checkout

Enable Apple Pay on DigetPay hosted checkout — no merchant code required.

With Hosted Checkout, DigetPay renders the Apple Pay button directly on the checkout page. You do not need to implement Apple Pay JavaScript, merchant validation, or domain verification on your website.

No Apple Pay code required: DigetPay handles the Apple Pay checkout flow end-to-end.

🚧

Apple Pay requirement: Include customerPhone in the Create Payment Link request (POST /payment/checkout/intiate). The phone number is not collected on the checkout page.


How It Works

sequenceDiagram
  participant Shop as Your Server
  participant API as DigetPay API
  participant Checkout as DigetPay Checkout
  participant Apple as Apple Pay

  Shop->>API: Create Payment Link<br/>(includes customerPhone)
  API-->>Shop: redirectUrl
  Shop->>Checkout: Redirect customer
  Checkout->>Apple: Present Apple Pay
  Apple-->>Checkout: Customer authorizes payment
  Checkout->>Shop: Redirect to successUrl or failureUrl

Create a Payment Link

Include customerPhone when creating the payment link:

{
  "merchantOrderId": "ORD-1001",
  "amount": 10.00,
  "currency": "SAR",
  "customerName": "Ahmed Ali",
  "customerEmail": "[email protected]",
  "customerPhone": "501223324",
  "successUrl": "https://yourstore.com/checkout/success",
  "failureUrl": "https://yourstore.com/checkout/failure"
}
FieldApple Pay Requirement
customerPhoneRequired
customerEmailRecommended
Merchant Apple Pay codeNot required
📘

Staging API: https://fin-api.digetpay.com/v1
Production API: https://api.digetpay.com/v1


Apple Pay on Safari & iOS

Safari on iPhone and iPad provides the native Apple Pay experience on DigetPay Hosted Checkout. The customer can authorize the payment using Face ID, Touch ID, or their device passcode without leaving the checkout flow.

Safari on Mac also supports Apple Pay where the device and account configuration meet Apple's requirements.

📘

Prerequisite: Include customerPhone when creating the payment link. No Apple Pay configuration is required on your website.

🚧

The customer must have Apple Pay configured with an eligible payment card in Apple Wallet, and Apple Pay must be available for their region and device.

Customer flow

sequenceDiagram
  participant Customer as Customer (Safari)
  participant Checkout as DigetPay Checkout
  participant Apple as Apple Pay

  Customer->>Checkout: Opens redirectUrl
  Checkout->>Customer: Shows Apple Pay button
  Customer->>Apple: Taps Apple Pay
  Apple->>Customer: Face ID / Touch ID / Passcode
  Apple-->>Checkout: Payment authorized
  Checkout->>Customer: Redirect to successUrl

Customer steps

  1. The customer opens the redirectUrl in Safari on an iPhone, iPad, or Mac.
  2. DigetPay Checkout displays the Apple Pay button when Apple Pay is available.
  3. The customer selects Apple Pay.
  4. Apple displays the native payment sheet.
  5. The customer authenticates using Face ID, Touch ID, or their device passcode.
  6. The payment is processed.
  7. The customer is redirected to your configured successUrl or failureUrl.

Safari & iOS requirements

RequirementDetail
BrowserSafari
DeviceCompatible iPhone, iPad, or Mac
Apple WalletCustomer must have an eligible payment card configured
customerPhoneSent when creating the payment link
HTTPSRequired for the checkout flow
❗️

If the Apple Pay button does not appear, first verify that customerPhone was included when the payment link was created. The phone number is not collected on the hosted checkout page.


Apple Pay on Desktop

Customers using Chrome on a desktop may complete Apple Pay through the desktop QR flow when supported.

  1. Customer opens the hosted checkout in Chrome.
  2. The checkout displays the Apple Pay desktop QR option.
  3. Customer scans the QR code with a compatible iPhone.
  4. Apple Pay opens on the iPhone.
  5. Customer authenticates and completes the payment.
  6. The hosted checkout completes the transaction and redirects according to the configured flow.

Desktop QR →


What You Do Not Need

When using Hosted Checkout, you do not need to configure:

ItemRequired?
Apple Pay JavaScript on your websiteNo
Merchant validationNo
Merchant identity certificateNo
Domain association file on your domainNo
Apple Developer Merchant ID setupNo

DigetPay handles the Apple Pay implementation and checkout flow.


Confirm Payment

A redirect to successUrl does not guarantee that the payment was successful.

Always confirm the final payment status using:

  • The Transaction Status API, or
  • A Webhook

Query Transaction Status →


Testing

Test Apple Pay using the Fin staging environment before moving to production.

For Hosted Checkout testing:

  • Use your Fin staging x-api-key.
  • Include customerPhone when creating the payment link.
  • Test Apple Pay on Safari using a compatible Apple device.
  • Test the desktop QR flow where applicable.
  • Confirm the final transaction status using the status API or webhook.

Apple Pay Testing →


Next Steps


Did this page help you?