Documentation

Hey friend! We are co-hosting a conference with Software Mansion, learn more.

Payments

Expo includes support for payments through Stripe and Apple Pay on iOS via ExpoKit, and Stripe on Android (plus Android Pay via ExpoKit).
Need more help than what's on the page? The Payments module is largely based off tipsi-stripe. The documentation and questions there may prove helpful.
We encourage you to look at our examples of ExpoKit apps.
Note: (Android only) If you are using Expo Client then the setup has already been done for you. Also, the way you should use payments is slightly different. Instead of importing from 'expo-payments-stripe' use the following code:
import { DangerZone } from 'expo';
const { Stripe } = DangerZone;

If you haven't done payments with Stripe before, create an account with Stripe. After getting the account set up, navigate to the Stripe API dashboard. Here, you'll need to make a note of the Publishable key and Secret key listed.

The Payments module is currently only supported through EXPaymentsStripe pod on iOS.
First, eject your Expo project using ExpoKit (refer to Eject to ExpoKit for more information). Then, add expo-payments-stripe to the list of dependencies of your project and install the dependencies. Then, navigate to and open your-project-name/ios/Podfile. Add EXPaymentsStripe to your Podfile's subspecs. Example:
...
target 'your-project-name' do
  ...

  pod 'EXPaymentsStripe',
    :path => "../node_modules/expo-payments-stripe/ios",
    :inhibit_warnings => true

  ...
  pod 'React',
  ...
Finally, make sure CocoaPods is installed and run pod install in your-project-name/ios. This will add the Payments module files to your project and the corresponding dependencies.

You don't need to make this step if you're not going to use sources.
Follow Stripe instructions. If you have problems with this step just look at files: Info.plist and AppDelegate.m in one of our examples.

Note: These steps are required only if you have ejected your app with SDK < 30. If at the moment of ejecting you had sdkVersion set to 30 or higher in your app.json, the following setup should have been performed automatically.
  1. Add these lines into your settings.gradle file.
include ':expo-payments-stripe'
project(':expo-payments-stripe').projectDir = new File(rootProject.projectDir, '../node_modules/expo-payments-stripe/android')
  1. Add dependencies in your build.gradle file.
implementation project(':expo-payments-stripe')
  1. Force specific com.android.support:design version in your build.gradle file.
  android {
    ...
    configurations.all {
      resolutionStrategy.force 'com.android.support:design:27.1.0'
    }
    ...
  }
  1. Exclude old version of CreditCardEntry in your-project/android/app/build.gradle file.
    implementation('host.exp.exponent:expoview:29.0.0@aar') {
      transitive = true
      exclude group: 'com.squareup.okhttp3', module: 'okhttp'
      exclude group: 'com.github.thefuntasty', module: 'CreditCardEntry' // add this line
      exclude group: 'com.squareup.okhttp3', module: 'okhttp-urlconnection'
    }
  1. Make sure your list of repositories in build.gradle contains jitpack.
    allprojects {
      repositories {
        ...
        maven { url "https://jitpack.io" }
        ...
      }
    }

You don't need to make this step if you're not going to use sources.
Add the following code to your AndroidManifest.xml, replacing your_scheme with the URI scheme you're going to use when specifying return URL for payment process.
      ...
      <activity
          android:exported="true"
          android:launchMode="singleTask"
          android:name="expo.modules.payments.stripe.RedirectUriReceiver"
          android:theme="@android:style/Theme.Translucent.NoTitleBar.Fullscreen">
          <intent-filter>
              <action android:name="android.intent.action.VIEW" />
              <category android:name="android.intent.category.DEFAULT" />
              <category android:name="android.intent.category.BROWSABLE" />

              <data android:scheme="your_scheme" />
          </intent-filter>
      </activity>
      ...
If you have problems with this step just look at AndroidManifest.xml in one of our examples. Remember to use the same scheme as the one which was set in Info.plist file (only if you are also developing app for iOS).

import { PaymentsStripe as Stripe } from 'expo-payments-stripe';

...
Stripe.setOptionsAsync({
    ...
});
...

First, initialize the Payments module with your credentials:
Stripe.setOptionsAsync({
  publishableKey: 'PUBLISHABLE_KEY', // Your key
  androidPayMode: 'test', // [optional] used to set wallet environment (AndroidPay)
  merchantId: 'your_merchant_id', // [optional] used for payments with ApplePay
});

Creates token based on passed card params.
params — An object with the following keys:
KeyTypeDescription
number (Required)StringThe card’s number
expMonth (Required)NumberThe card’s expiration month
expYear (Required)NumberThe card’s expiration year
cvcStringThe card’s security code, found on the back
nameStringThe cardholder’s name
addressLine1StringThe first line of the billing address
addressLine2StringThe second line of the billing address
addressCityStringCity of the billing address
addressStateStringState of the billing address
addressZipStringZip code of the billing address
addressCountryStringCountry for the billing address
brand (Android)StringBrand of this card. Can be one of: JCB ‖ American Express ‖ Visa ‖ Discover ‖ Diners Club ‖ MasterCard ‖ Unknown
last4 (Android)Stringlast 4 digits of the card
fingerprint (Android)StringThe card fingerprint
funding (Android)StringThe funding type of the card. Can be one of: debit ‖ credit ‖ prepaid ‖ unknown
country (Android)StringISO country code of the card itself
currencyStringThree-letter ISO currency code representing the currency paid out to the bank account. This is only applicable when tokenizing debit cards to issue payouts to managed accounts. You should not set it otherwise. The card can then be used as a transfer destination for funds in this currency
const params = {
  // mandatory
  number: '4242424242424242',
  expMonth: 11,
  expYear: 17,
  cvc: '223',
  // optional
  name: 'Test User',
  currency: 'usd',
  addressLine1: '123 Test Street',
  addressLine2: 'Apt. 5',
  addressCity: 'Test City',
  addressState: 'Test State',
  addressCountry: 'Test Country',
  addressZip: '55555',
};

const token = await stripe.createTokenWithCardAsync(params);

// Client specific code
// api.sendTokenToBackend(token)
Remember to initialize the Payments module before creating token.

Launch Add Card view to to accept payment.
options (iOS only) — An object with the following keys:
KeyTypeDescription
requiredBillingAddressFieldsStringThe billing address fields the user must fill out when prompted for their payment details. Can be one of: full or zip or not specify to disable
prefilledInformationObjectYou can set this property to pre-fill any information you’ve already collected from your user
managedAccountCurrencyStringRequired to be able to add the card to an account (in all other cases, this parameter is not used). More info
themeObjectCan be used to visually style Stripe-provided UI
options.prefilledInformation — An object with the following keys:
KeyTypeDescription
emailStringThe user’s email address
phoneStringThe user’s phone number
billingAddressObjectThe user’s billing address. When set, the add card form will be filled with this address
options.prefilledInformation.billingAddress — An object with the following keys:
KeyTypeDescription
nameStringThe user’s full name (e.g. "Jane Doe")
line1StringThe first line of the user’s street address (e.g. "123 Fake St")
line2StringThe apartment, floor number, etc of the user’s street address (e.g. "Apartment 1A")
cityStringThe city in which the user resides (e.g. "San Francisco")
stateStringThe state in which the user resides (e.g. "CA")
postalCodeStringThe postal code in which the user resides (e.g. "90210")
countryStringThe ISO country code of the address (e.g. "US")
phoneStringThe phone number of the address (e.g. "8885551212")
emailStringThe email of the address (e.g. "jane@doe.com")
options.theme — An object with the following keys:
KeyTypeDescription
primaryBackgroundColorStringThe primary background color of the theme
secondaryBackgroundColorStringThe secondary background color of this theme
primaryForegroundColorStringThe primary foreground color of this theme. This will be used as the text color for any important labels in a view with this theme (such as the text color for a text field that the user needs to fill out)
secondaryForegroundColorStringThe secondary foreground color of this theme. This will be used as the text color for any supplementary labels in a view with this theme (such as the placeholder color for a text field that the user needs to fill out)
accentColorStringThe accent color of this theme - it will be used for any buttons and other elements on a view that are important to highlight
errorColorStringThe error color of this theme - it will be used for rendering any error messages or view

const options = {
  requiredBillingAddressFields: 'full',
  prefilledInformation: {
    billingAddress: {
      name: 'Gunilla Haugeh',
      line1: 'Canary Place',
      line2: '3',
      city: 'Macon',
      state: 'Georgia',
      country: 'US',
      postalCode: '31217',
    },
  },
};

const token = await stripe.paymentRequestWithCardFormAsync(options);

// Client specific code
// api.sendTokenToBackend(token)

Creates source object based on params. Sources are used to create payments for a variety of payment methods
NOTE: For sources that require redirecting your customer to authorize the payment, you need to specify a return URL when you create the source. This allows your customer to be redirected back to your app after they authorize the payment. The prefix before ':' in your return URL should be the same as the scheme in your info.plist and AndroidManifest.xml. If You are not sure about this step look at above sections "Register hook in order to Stripe could process source authorization".
NOTE: If you are using Expo Client or an ejected Expo application, do not specify returnURL.
params — An object with the following keys:
Depending on the type you need to provide different params. Check the STPSourceParams docs for reference
KeyTypeDescription
type (Required)StringThe type of the source to create. Can be one of: bancontact ‖ bitcoin ‖ card ‖ griopay ‖ ideal ‖ sepaDebit ‖ sofort ‖ threeDSecure ‖ alipay
amountNumberA positive number in the smallest currency unit representing the amount to charge the customer (e.g., 1099 for a €10.99 payment)
nameStringThe full name of the account holder
returnURLStringThe URL the customer should be redirected to after they have successfully verified the payment
statementDescriptorStringA custom statement descriptor for the payment
currencyStringThe currency associated with the source. This is the currency for which the source will be chargeable once ready
emailStringThe customer’s email address
bankStringThe customer’s bank
ibanStringThe IBAN number for the bank account you wish to debit
addressLine1StringThe bank account holder’s first address line (optional)
cityStringThe bank account holder’s city
postalCodeStringThe bank account holder’s postal code
countryStringThe bank account holder’s two-letter country code (sepaDebit) or the country code of the customer’s bank (sofort)
cardStringThe ID of the card source

const params = {
  type: 'alipay',
  amount: 5,
  currency: 'EUR',
  returnURL: 'expaymentsstripe://stripe-redirect',
};

const source = await stripe.createSourceWithParamsAsync(params);

// Client specific code
// api.sendSourceToBackend(source)

Remember: to use Apple Pay on a real device, you need to set up apple pay first.

Opens the user interface to set up credit cards for Apple Pay.

Returns whether the user can make Apple Pay payments with specified options. If there are no configured payment cards, this method always returns false. Return true if the user can make Apple Pay payments through any of the specified networks; otherwise, false.
NOTE: iOS Simulator always returns true
options
KeyTypeDescription
networksArray[String]Indicates whether the user can make Apple Pay payments through the specified network. Available networks: americanexpress ‖ discover ‖ mastercard ‖ visa. If option does not specify we pass all available networks under the hood.

import { PaymentsStripe as Stripe } from 'expo-payments-stripe';

await Stripe.canMakeApplePayPaymentsAsync();
import { PaymentsStripe as Stripe } from 'expo-payments-stripe';

await Stripe.canMakeApplePayPaymentsAsync(['american_express', 'discover']);

Returns whether the user can make Apple Pay payments. User may not be able to make payments for a variety of reasons. For example, this functionality may not be supported by their hardware, or it may be restricted by parental controls. Returns true if the device supports making payments; otherwise, false.
NOTE: iOS Simulator always returns true

Launch the  Pay view to accept payment.
items — An array of object with the following keys:
KeyTypeDescription
labelStringA short, localized description of the item.
amountStringThe summary item’s amount.
typeStringThe summary item’s type. Must be "pending" or "final". Defaults to "final".
NOTE: The final item should represent your company; it'll be prepended with the word "Pay" (i.e. "Pay Tipsi, Inc $50")
options — An object with the following keys:
KeyTypeDescription
requiredBillingAddressFieldsArray[String]A bit field of billing address fields that you need in order to process the transaction. Array should contain one of: all ‖ name ‖ email ‖ phone ‖ postal_address or not specify to disable
requiredShippingAddressFieldsArray[String]A bit field of shipping address fields that you need in order to process the transaction. Array should contain one of: all ‖ name ‖ email ‖ phone ‖ postal_address or not specify to disable
shippingMethodsArrayAn array of shippingMethod objects that describe the supported shipping methods.
currencyCodeStringThe three-letter ISO 4217 currency code. Default is USD
countryCodeStringThe two-letter code for the country where the payment will be processed. Default is US
shippingTypeStringAn optional value that indicates how purchased items are to be shipped. Default is shipping. Available options are: shipping ‖ delivery ‖ storepickup ‖ servicepickup
shippingMethod — An object with the following keys:
KeyTypeDescription
idStringA unique identifier for the shipping method, used by the app
idStringA short, localized description of the shipping method
labelStringA unique identifier for the shipping method, used by the app
detailStringA user-readable description of the shipping method
amountStringThe shipping method’s amount

const items = [
  {
    label: 'Whisky',
    amount: '50.00',
  },
  {
    label: 'Tipsi, Inc',
    amount: '50.00',
  },
];

const shippingMethods = [
  {
    id: 'fedex',
    label: 'FedEX',
    detail: 'Test @ 10',
    amount: '10.00',
  },
];

const options = {
  requiredBillingAddressFields: ['all'],
  requiredShippingAddressFields: ['phone', 'postal_address'],
  shippingMethods,
};

const token = await stripe.paymentRequestWithApplePayAsync(items, options);

extra — An object with the following keys
KeyTypeDescription
shippingMethodObjectSelected shippingMethod object
billingContactObjectThe user's billing contact object
shippingContactObjectThe user's shipping contact object
contact — An object with the following keys
KeyTypeDescription
nameStringThe contact’s name
phoneNumberStringThe contact’s phone number
emailAddressStringThe contact’s email address
streetStringThe street name in a postal address
cityStringThe city name in a postal address
stateStringThe state name in a postal address
countryStringThe country name in a postal address
ISOCountryCodeStringThe ISO country code for the country in a postal address
postalCodeStringThe postal code in a postal address
supplementarySubLocalityStringThe contact’s sublocality

After paymentRequestWithApplePayAsync you should complete the operation by calling completeApplePayRequestAsync or cancel if an error occurred. This closes Apple Pay. (resolves to undefined, you do not need to store the Promise)
const items = [
  {
    label: 'Whisky',
    amount: '50.00',
  },
  {
    label: 'Tipsi, Inc',
    amount: '50.00',
  },
];

const shippingMethods = [
  {
    id: 'fedex',
    label: 'FedEX',
    detail: 'Test @ 10',
    amount: '10.00',
  },
];

const options = {
  requiredBillingAddressFields: 'all',
  requiredShippingAddressFields: 'all',
  shippingMethods,
};

try {
  const token = await stripe.paymentRequestWithApplePayAsync(items, options);

  // Client specific code
  // api.sendTokenToBackend(token)

  // You should complete the operation by calling
  stripe.completeApplePayRequestAsync();
} catch (error) {
  // Or cancel if an error occurred
  // stripe.cancelApplePayRequestAsync()
}

Android Pay (also known as Google Pay) is currently only supported on ExpoKit apps. To add it to your app, add the following lines to your AndroidManifest.xml file, inside of the <application>....</applicaton> tags:
<meta-data
  android:name="com.google.android.gms.wallet.api.enabled"
  android:value="true" />

Indicates whether or not the device supports AndroidPay. Returns a Boolean value.
import { PaymentsStripe as Stripe } from 'expo-payments-stripe';

await Stripe.deviceSupportsAndroidPayAsync();

Indicates whether or not the device supports AndroidPay and user has existing payment method. Returns a Boolean value.
import { PaymentsStripe as Stripe } from 'expo-payments-stripe';

await Stripe.canMakeAndroidPayPaymentsAsync();

options — An object with the following keys:
KeyTypeDescription
total_priceStringTotal price for items
currency_codeStringThree-letter ISO currency code representing the currency paid out to the bank account
shippingaddressrequired (Optional)BoolIs shipping address menu required? Default is false
billingaddressrequired (Optional)BoolIs billing address menu required? Default is false
line_itemsArrayArray of purchased items. Each item contains line_item
line_item — An object with the following keys:
KeyTypeDescription
currency_codeStringCurrency code string
descriptionStringShort description that will shown to user
total_priceStringTotal order price
unit_priceStringPrice per unit
quantityStringNumber of items

const options = {
  total_price: '80.00',
  currency_code: 'USD',
  shipping_address_required: false,
  billing_address_required: true,
  shipping_countries: ['US', 'CA'],
  line_items: [
    {
      currency_code: 'USD',
      description: 'Whisky',
      total_price: '50.00',
      unit_price: '50.00',
      quantity: '1',
    },
    {
      currency_code: 'USD',
      description: 'Vine',
      total_price: '30.00',
      unit_price: '30.00',
      quantity: '1',
    },
  ],
};

const token = await stripe.paymentRequestWithAndroidPayAsync(options);

// Client specific code
// api.sendTokenToBackend(token)
Example of token:
{ card:
  { currency: null,
    fingerprint: null,
    funding: "credit",
    brand: "MasterCard",
    number: null,
    addressState: null,
    country: "US",
    cvc: null,
    expMonth: 12,
    addressLine1: null,
    expYear: 2022,
    addressCountry: null,
    name: null,
    last4: "4448",
    addressLine2: null,
    addressCity: null,
    addressZip: null
  },
  created: 1512322244000,
  used: false,
  extra: {
    email: "randomemail@mail.com",
    billingContact: {
      postalCode: "220019",
      name: "John Doe",
      locality: "NY",
      countryCode: "US",
      administrativeArea: "US",
      address1: "Time square 1/11"
    },
    shippingContact: {}
  },
  livemode: false,
  tokenId: "tok_1BV1IeDZwqOES60ZphBXBoDr"
}

A token object returned from submitting payment details to the Stripe API via:
  • paymentRequestWithApplePayAsync
  • paymentRequestWithCardFormAsync
  • createTokenWithCardAsync
token — an object with the following keys
KeyTypeDescription
tokenIdStringThe value of the token. You can store this value on your server and use it to make charges and customers
createdNumberWhen the token was created
livemodeNumberWhether or not this token was created in livemode. Will be 1 if you used your Live Publishable Key, and 0 if you used your Test Publishable Key
cardObjectThe credit card details object that were used to create the token
bankAccountObjectThe external (bank) account details object that were used to create the token
extraObjectAn additional information that method can provide
card — an object with the following keys
KeyTypeDescription
cardIdStringThe Stripe ID for the card
brandStringThe card’s brand. Can be one of: **JCB **‖ **American Express **‖ **Visa **‖ **Discover **‖ **Diners Club **‖ **MasterCard **‖ Unknown
funding (iOS)StringThe card’s funding. Can be one of: **debit **‖ **credit **‖ **prepaid **‖ unknown
last4StringThe last 4 digits of the card
dynamicLast4 (iOS)StringFor cards made with Apple Pay, this refers to the last 4 digits of the Device Account Number for the tokenized card
isApplePayCard (iOS)BoolWhether or not the card originated from Apple Pay
expMonthNumberThe card’s expiration month. 1-indexed (i.e. 1 == January)
expYearNumberThe card’s expiration year
countryStringTwo-letter ISO code representing the issuing country of the card
currencyStringThis is only applicable when tokenizing debit cards to issue payouts to managed accounts. The card can then be used as a transfer destination for funds in this currency
nameStringThe cardholder’s name
addressLine1StringThe cardholder’s first address line
addressLine2StringThe cardholder’s second address line
addressCityStringThe cardholder’s city
addressStateStringThe cardholder’s state
addressCountryStringThe cardholder’s country
addressZipStringThe cardholder’s zip code
bankAccount
KeyTypeDescription
routingNumberStringThe routing number of this account
accountNumberStringThe account number for this BankAccount.
countryCodeStringThe two-letter country code that this account was created in
currencyStringThe currency of this account
accountHolderNameStringThe account holder's name
accountHolderTypeStringthe bank account type. Can be one of: **company **‖ individual
fingerprintStringThe account fingerprint
bankNameStringThe name of bank
last4StringThe last four digits of the account number

{
  tokenId: 'tok_19GCAQI5NuVQgnjeKNE32K0p',
  created: 1479236426,
  livemode: 0,
  card: {
    cardId: 'card_19GCAQI5NuVQgnjeRZizG4U3',
    brand: 'Visa',
    funding: 'credit',
    last4: '4242',
    expMonth: 4,
    expYear: 2024,
    country: 'US',
    name: 'Eugene Grissom',
    addressLine1: 'Green Street',
    addressLine2: '3380',
    addressCity: 'Nashville',
    addressState: 'Tennessee',
    addressCountry: 'US',
    addressZip: '37211',
  },
  bankAccount: {
    bankName: 'STRIPE TEST BANK',
    accountHolderType: 'company',
    last4: '6789',
    accountHolderName: 'Test holder name',
    currency: 'usd',
    fingerprint: 'afghsajhaartkjasd',
    countryCode: 'US',
    accountNumber: '424542424',
    routingNumber: '110000000',
  },
}

A source object returned from creating a source (via createSourceWithParamsAsync) with the Stripe API.
source — an object with the following keys:
KeyTypeDescription
amountNumberThe amount associated with the source
clientSecretStringThe client secret of the source. Used for client-side polling using a publishable key
createdNumberWhen the source was created
currencyStringThe currency associated with the source
flowStringThe authentication flow of the source. Can be one of: none ‖ redirect ‖ verification ‖ receiver ‖ unknown
livemodeBoolWhether or not this source was created in livemode. Will be true if you used your Live Publishable Key, and false if you used your Test Publishable Key
metadataObjectA set of key/value pairs associated with the source object
ownerObjectInformation about the owner of the payment instrument
receiverObject (Optional)Information related to the receiver flow. Present if the source is a receiver
redirectObject (Optional)Information related to the redirect flow. Present if the source is authenticated by a redirect
statusStringThe status of the source. Can be one of: pending ‖ chargable ‖ consumed ‖ cancelled ‖ failed
typeStringThe type of the source. Can be one of: bancontact ‖ card ‖ griopay ‖ ideal ‖ sepaDebit ‖ sofort ‖ threeDSecure ‖ alipay ‖ unknown
usageStringWhether this source should be reusable or not. Can be one of: reusable ‖ single ‖ unknown
verificationObject (Optional)Information related to the verification flow. Present if the source is authenticated by a verification
detailsObjectInformation about the source specific to its type
cardDetailsObject (Optional)If this is a card source, this property contains information about the card
sepaDebitDetailsObject (Optional)If this is a SEPA Debit source, this property contains information about the sepaDebit
owner
KeyTypeDescription
addressObject (Optional)Owner’s address
emailString (Optional)Owner’s email address
nameString (Optional)Owner’s full name
phoneString (Optional)Owner’s phone number
verifiedAddressObject (Optional)Verified owner’s address
verifiedEmailString (Optional)Verified owner’s email address
verifiedNameString (Optional)Verified owner’s full name
verifiedPhoneString (Optional)Verified owner’s phone number
receiver
KeyTypeDescription
addressObjectThe address of the receiver source. This is the value that should be communicated to the customer to send their funds to
amountChargedNumberThe total amount charged by you
amountReceivedNumberThe total amount received by the receiver source
amountReturnedNumberThe total amount that was returned to the customer
redirect
KeyTypeDescription
returnURLStringThe URL you provide to redirect the customer to after they authenticated their payment
statusStringThe status of the redirect. Can be one of: pending ‖ succeeded ‖ failed ‖ unknown
urlStringThe URL provided to you to redirect a customer to as part of a redirect authentication flow
verification
KeyTypeDescription
attemptsRemainingNumberThe number of attempts remaining to authenticate the source object with a verification code
statusStringThe status of the verification. Can be one of: pending ‖ succeeded ‖ failed ‖ unknown
cardDetails
KeyTypeDescription
last4StringThe last 4 digits of the card
expMonthNumberThe card’s expiration month. 1-indexed (i.e. 1 == January)
expYearNumberThe card’s expiration year
brandStringThe issuer of the card. Can be one of: JCB ‖ American Express ‖ Visa ‖ Discover ‖ Diners Club ‖ MasterCard ‖ Unknown
funding (iOS)StringThe funding source for the card. Can be one of: debit ‖ credit ‖ prepaid ‖ unknown
countryStringTwo-letter ISO code representing the issuing country of the card
threeDSecureStringWhether 3D Secure is supported or required by the card. Can be one of: required ‖ optional ‖ notSupported ‖ unknown
sepaDebitDetails
KeyTypeDescription
last4StringThe last 4 digits of the account number
bankCodeStringThe account’s bank code
countryStringTwo-letter ISO code representing the country of the bank account
fingerprintStringThe account’s fingerprint
mandateReferenceStringThe reference of the mandate accepted by your customer
mandateURLStringThe details of the mandate accepted by your customer

Example

{
  livemode: false,
  amount: 50,
  owner: {},
  metadata: {},
  clientSecret: 'src_client_secret_BLnXIZxZprDmdhw3zv12123L',
  details: {
    native_url: null,
    statement_descriptor: null
  },
  type: 'alipay',
  redirect: {
    url: 'https://hooks.stripe.com/redirect/authenticate/src_1Az5vzE5aJKqY779Kes5s61m?client_secret=src_client_secret_BLnXIZxZprDmdhw3zv12123L',
    returnURL: 'example://stripe-redirect?redirect_merchant_name=example',
    status: 'succeeded'
  },
  usage: 'single',
  created: 1504713563,
  flow: 'redirect',
  currency: 'euro',
  status: 'chargable',
}

If you want to use Apple Pay for payments, you'll need to set up your merchant ID in XCode first. Note that you do not need to go through this process to use the Payments module - you can still process payments with Stripe without going through the steps in this section.
If you haven't already, set up an Apple Merchant ID via the Apple Developer Portal. Then, open the application in XCode and navigate to the capabilities tab. Enable Apple Pay and insert your merchant ID into the corresponding space.
Note: Apple Pay can be used only for real world items (ex. appeal, car sharing, food) and not virtual goods. For more information about proper usage of Apple Pay, visit Apple's Apple Pay guidelines and Acceptable Use.