# Add external payment methods Add external payment methods to the Mobile Payment Element. > We created a [custom payment methods](https://docs.stripe.com/payments/mobile/custom-payment-methods.md) feature that allows you to extend your payment integration with payment methods processed outside of Stripe. We recommend using it for your integration instead of external payment methods. [In-app Payments](https://docs.stripe.com/payments/mobile.md) can display external payment methods that you support in addition to the payment methods processed through Stripe. Integrating external payment methods requires additional integration work, because external payment method transactions are processed and finalized outside of Stripe. > #### External payment methods responsibility > > When customers choose an external payment method, your app handles the payment instead of Stripe processing it. To learn about your responsibilities and the ongoing availability of external payment methods, see the [external payment methods disclaimer](https://docs.stripe.com/payments/mobile/external-payment-methods.md#external-payment-methods-disclaimer). # iOS > This is a iOS for when platform is ios. View the full page at https://docs.stripe.com/payments/mobile/external-payment-methods?platform=ios. This guide adds an external payment method, Fawry, using the [Payment Sheet Accept In-app payments](https://docs.stripe.com/payments/mobile/accept-payment.md?platform=ios&type=payment) guide. See [the list of all available external payment methods](https://docs.stripe.com/payments/mobile/external-payment-methods.md#available-external-payment-methods). ## Before you begin 1. [Create a Stripe account](https://dashboard.stripe.com/register) or [sign in](https://dashboard.stripe.com/login). 1. Follow the [Payment Sheet example](https://docs.stripe.com/payments/mobile/accept-payment.md?platform=ios&type=payment) to complete a payments integration. 1. For each external payment method you want to add, complete its integration and confirm that it’s working in the region where you want to enable it. ## Add external payment method types When you create your `PaymentSheet.Configuration` object and initialize `PaymentSheet`, specify the external payment methods that you want to add to the Payment Element and a handler to complete the payment. This example adds Fawry: ```swift import StripePaymentSheet class MyCheckoutVC: UIViewController { func setUpPaymentSheet() { // ... var configuration = PaymentSheet.Configuration()configuration.externalPaymentMethodConfiguration = .init( externalPaymentMethods: ["external_fawry"] ) { externalPaymentMethodType, billingDetails in return await self.handleExternalPaymentMethod(type: externalPaymentMethodType, billingDetails: billingDetails) } // ... } func handleExternalPaymentMethod(type: String, billingDetails: STPPaymentMethodBillingDetails) async -> PaymentSheetResult { // ...explained in the next step } } ``` ## Complete the payment #### PaymentSheet When the customer taps the **Buy** button in PaymentSheet using an external payment method, it calls the handler with the type (for example, “external_fawry”) and any billing details that were collected. Your implementation completes the payment (for example, by using your external payment method provider’s SDK) and returns the result of the payment: `completed`, `canceled`, or `failure(error:)`. If you pass `.failure(error:)`, PaymentSheet displays the error using [errorDescription](https://developer.apple.com/documentation/foundation/localizederror/2946895-errordescription) for Swift errors and [localizedDescription](https://developer.apple.com/documentation/foundation/nserror/1414418-localizeddescription) for NSErrors. ```swift import StripePaymentSheet class MyCheckoutVC: UIViewController { func setUpPaymentSheet() { // ... var configuration = PaymentSheet.Configuration() configuration.externalPaymentMethods = .init( externalPaymentMethods: ["external_fawry"] ) { [weak self] externalPaymentMethodType, billingDetails in return await self?.handleExternalPaymentMethod(type: externalPaymentMethodType, billingDetails: billingDetails) } // ... } func handleExternalPaymentMethod(type: String, billingDetails: STPPaymentMethodBillingDetails) async -> PaymentSheetResult {// Your implementation should complete the payment with the payment method provider // When the payment completes, cancels, or fails, return the result // Note you can present on top of PaymentSheet by using the `self.presentedViewController`. // This example code just immediately fails: let exampleError = NSError(domain: "MyErrorDomain", code: 0, userInfo: [NSLocalizedDescriptionKey: "Failed to complete payment!"]) return .failed(error: exampleError) } } ``` #### PaymentSheet.FlowController When you call [confirm](https://stripe.dev/stripe-ios/stripepaymentsheet/documentation/stripepaymentsheet/paymentsheet/flowcontroller/confirm\(from:completion:\)) on your `PaymentSheet.FlowController` instance and the customer has selected an external payment method, it calls the handler with the type (for example, “external_fawry”) and any billing details that were collected in the sheet. Your implementation completes the payment (for example, by using your external payment method provider’s SDK) and returns the result of the payment: `completed`, `canceled`, or `failure(error:)`. ```swift import StripePaymentSheet class MyCheckoutVC: UIViewController { func setUpPaymentSheet() { // ... var configuration = PaymentSheet.Configuration() configuration.externalPaymentMethods = .init( externalPaymentMethods: ["external_fawry"] ) { [weak self] externalPaymentMethodType, billingDetails in return await self?.handleExternalPaymentMethod(type: externalPaymentMethodType, billingDetails: billingDetails) } // ... } func handleExternalPaymentMethod(type: String, billingDetails: STPPaymentMethodBillingDetails) async -> PaymentSheetResult {// Your implementation should complete the payment with the payment method provider // When the payment completes, cancels, or fails, return the result // This example code just immediately fails: let exampleError = NSError(domain: "MyErrorDomain", code: 0, userInfo: [NSLocalizedDescriptionKey: "Failed to complete payment!"]) return .failed(error: exampleError) } } ``` ## Optional: Position external payment methods External payment methods aren’t intelligently ranked by Stripe’s smart ordering logic because Stripe doesn’t have context on these payment methods. By default, they appear after Stripe-supported payment methods. Set `PaymentSheet.Configuration.paymentMethodOrder` to explicitly position the external payment method in the Payment Element. The Stripe-supported payment methods following the external payment method are still intelligently ranked. ```swift var configuration = PaymentSheet.Configuration()// Show cards first, followed by external_fawry, followed by all other payment methods configuration.paymentMethodOrder = ["card", "external_fawry"] ``` ## Test your integration 1. Go through your checkout flow and verify that the Payment Element displays Fawry. This example configures Fawry in the second position after cards.![The Payment Element when Fawry is added](https://b.stripecdn.com/docs-statics-srv/assets/display-fawry-mobile.70eb4f257a70e8e50d37e2a454586934.png) 1. Choose the Fawry payment method.![The Payment Element when Fawry is selected](https://b.stripecdn.com/docs-statics-srv/assets/select-fawry-mobile.0ae3d2034319afc2bf1320e53b561edb.png) 1. Click **Pay now** to test your existing Fawry integration. Verify that your integration completes the transaction and that any post-payment actions (for example, displays a confirmation page, success message, or failure message) still work with your Fawry integration. ## Dashboard considerations [PaymentIntents](https://docs.stripe.com/api/payment_intents.md) for transactions processed with an external payment method provider have an `incomplete` status in the Stripe Dashboard. Stripe isn’t involved in external payment method transactions and can’t determine the status of these transactions. If you [collect payment details before creating an Intent](https://docs.stripe.com/payments/accept-a-payment-deferred.md), you won’t see any `incomplete` transactions in the Stripe Dashboard for transactions that were processed with an external payment method provider. ## External payment methods disclaimer You can use the Stripe Mobile Payment Element to show some external payment methods that aren’t supported by Stripe but that you directly integrate with. When customers choose an external payment method, your app completes the transaction instead of the Stripe Mobile Payment Element. You acknowledge that: 1. External payment methods aren’t offered nor supported by Stripe. The operation and support of external payment methods is provided by the external payment method provider. 1. You’re responsible for maintaining a direct integration with the external payment method provider. 1. You need to maintain an agreement with the external payment method provider and are responsible for complying with your agreements with each external payment method provider. 1. You’re responsible for obtaining all necessary rights to use the external payment method provider’s marks and logos within your checkout as described in these docs. 1. Stripe isn’t responsible for the processing of any transactions with any external payment method provider including, for example, any charges, refunds, disputes, settlements or funds flows. 1. You or the external payment method provider are responsible for the completion of the purchase flow after a customer has selected an external payment method, including, for example, the order confirmation and reconciliation of orders. 1. You’re responsible for properly configuring the redirect URL for the external payment method. 1. You must immediately remove any external payment methods in the event your agreements with any external payment method provider terminate or Stripe removes the availability of an external payment method. 1. You’re only permitted to integrate with and present in the Payment Element the external payment methods listed in this guide. 1. You’re solely responsible for making sure that buyers are redirected correctly to their chosen external payment method. ### Ongoing availability of external payment methods Stripe might at any time decide to remove the availability of any payment method as an external payment method. Stripe will notify you of any removal of an external payment method that you’re using, and you must immediately remove the external payment method in your code. Failure to do so will result in the external payment method not rendering to your customers. ## Available external payment methods You can display the following external payment methods. You must use the corresponding external payment method type in your code. | Region | Payment method | External payment method type | | ------------ | ----------------------------------------- | ----------------------------------- | | AMER | Interac | `external_interac` | | APAC | au PAY | `external_au_pay` | | APAC | atone | `external_atone` | | APAC | Touch’n Go | `external_tng_ewallet` | | APAC | ソフトバンクまとめて支払い (Softbank carrier payments) | `external_softbank_carrier_payment` | | APAC | Toss Pay | `external_toss_pay` | | APAC | Laybuy | `external_laybuy` | | APAC | Bank Pay | `external_bank_pay` | | APAC | auかんたん決済 (au easy payments) | `external_au_easy_payment` | | APAC | BitCash | `external_bitcash` | | APAC | Azupay | `external_azupay` | | APAC | d払い (d-barai) | `external_dbarai` | | APAC | FamiPay | `external_famipay` | | APAC | GCash | `external_gcash` | | APAC | GrabPay Later | `external_grabpay_later` | | APAC | MoMo | `external_momo` | | APAC | NET CASH | `external_net_cash` | | APAC | Octopus | `external_octopus` | | APAC | Paidy | `external_paidy` | | APAC | PayPay | `external_paypay` | | APAC | PlanPay | `external_planpay` | | APAC | ペイジー (Pay-easy) | `external_pay_easy` | | APAC | 楽天ペイ (Rakuten Pay) | `external_rakuten_pay` | | APAC | メルペイ (Merpay) | `external_merpay` | | APAC | WebMoney | `external_webmoney` | | APAC, Europe | Shopback Pay | `external_shopback_pay` | | Europe | Aplazame | `external_aplazame` | | Europe | Bizum | `external_bizum` | | Europe | Divido | `external_divido` | | Europe | Fonix | `external_fonix` | | Europe | Iwocapay | `external_iwocapay` | | Europe | KBC | `external_kbc` | | Europe | Nexi Pay | `external_nexi_pay` | | Europe | Oney | `external_oney` | | Europe | Payconiq | `external_payconiq` | | Europe | PayPo | `external_paypo` | | Europe | Sofinco | `external_sofinco` | | Europe | Postepay | `external_postepay` | | Europe | PostFinance | `external_postfinance` | | Europe | Scalapay | `external_scalapay` | | Europe | TrueLayer | `external_truelayer` | | Europe | Walley | `external_walley` | | Europe | YounitedPay | `external_younited_pay` | | Global | LINE Pay | `external_line_pay` | | Global | paysafecard | `external_paysafecard` | | Global | Samsung Pay | `external_samsung_pay` | | Global | Sezzle | `external_sezzle` | | LATAM | Dapp | `external_dapp` | | LATAM | PicPay | `external_picpay` | | MEA | Tabby | `external_tabby` | | MEA | Benefit | `external_benefit` | | MEA | Fawry | `external_fawry` | # Android > This is a Android for when platform is android. View the full page at https://docs.stripe.com/payments/mobile/external-payment-methods?platform=android. This guide adds an external payment method, Fawry, using the [Payment Sheet Accept In-app payments](https://docs.stripe.com/payments/mobile/accept-payment.md?platform=android&type=payment) guide. See [the list of all available external payment methods](https://docs.stripe.com/payments/mobile/external-payment-methods.md#available-external-payment-methods). ## Before you begin 1. [Create a Stripe account](https://dashboard.stripe.com/register) or [sign in](https://dashboard.stripe.com/login). 1. Follow the [Payment Sheet example](https://docs.stripe.com/payments/mobile/accept-payment.md?platform=android&type=payment) to complete a payments integration. 1. For each external payment method you want to add, complete its integration and confirm that it’s working in the region where you want to enable it. ## Add external payment method types When you create your `PaymentSheet.Configuration` object and initialize `PaymentSheet`, specify the external payment methods that you want to add to the Payment Element and a handler to complete the payment. This example adds Fawry: ```kotlin import com.stripe.android.paymentsheet.PaymentSheet class CheckoutActivity : AppCompatActivity() { @Composable private fun CheckoutScreen() { val paymentSheet = rememberPaymentSheet(externalPaymentMethodConfirmHandler = viewModel.fawryConfirmHandler, ) { paymentResult -> when (paymentResult) { is PaymentSheetResult.Completed -> showToast("Payment complete!") is PaymentSheetResult.Canceled -> showToast("Payment canceled!") is PaymentSheetResult.Failed -> { error = paymentResult.error.localizedMessage ?: paymentResult.error.message } } } private fun onPayClicked( paymentSheet: PaymentSheet, paymentIntentClientSecret: String, ) { val configuration = PaymentSheet.Configuration.Builder(merchantDisplayName = "Example, Inc.").externalPaymentMethods(listOf("external_fawry")) .build() // Present Payment Sheet paymentSheet.presentWithPaymentIntent(paymentIntentClientSecret, configuration) } } } class FawryConfirmHandler(...) : ExternalPaymentMethodConfirmHandler { override fun confirmExternalPaymentMethod(externalPaymentMethodType: String, billingDetails: PaymentMethod.BillingDetails) { // ...explained in the next step } } ``` ## Complete the payment #### PaymentSheet When the customer taps the **Pay** button in PaymentSheet using an external payment method, it calls the handler with the type (for example, “external_fawry”) and any billing details that were collected. Your implementation completes the payment (for example, by using your external payment method provider’s SDK) and calls `ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult()` with the result of the payment. If you pass `ExternalPaymentMethod.failed(displayMessage)`, PaymentSheet displays the `displayMessage`. ```kotlin import com.stripe.android.paymentsheet.ExternalPaymentMethodConfirmHandler class FawryConfirmHandler( private val context: Context, /* Any other parameters required to complete payment. */ ) : ExternalPaymentMethodConfirmHandler { override fun confirmExternalPaymentMethod( externalPaymentMethodType: String, billingDetails: PaymentMethod.BillingDetails ) {/* Your implementation should complete the payment with the payment method provider. When the payment completes, cancels, or fails, call `ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult` with the result. This example code just immediately fails: */ ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult( context, ExternalPaymentMethodResult.failed(displayMessage = "Failed to complete payment"), ) } } ``` #### PaymentSheet.FlowController When you call [confirm](https://stripe.dev/stripe-android/paymentsheet/com.stripe.android.paymentsheet/-payment-sheet/-flow-controller/confirm.html) on your `PaymentSheet.FlowController` instance and the customer has selected an external payment method, it calls the handler with the type (for example, “external_fawry”) and any billing details that were collected. Your implementation completes the payment (for example, by using your external payment method provider’s SDK) and calls `ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult()` with the result of the payment. If your implementation might exit without confirming payment, ensure you call `ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult` with a canceled result. ```kotlin import com.stripe.android.paymentsheet.ExternalPaymentMethodConfirmHandler class FawryConfirmHandler( private val context: Context, /* Any other parameters required to complete payment. */ ) : ExternalPaymentMethodConfirmHandler { override fun confirmExternalPaymentMethod( externalPaymentMethodType: String, billingDetails: PaymentMethod.BillingDetails ) {/* Your implementation should complete the payment with the payment method provider. When the payment completes, cancels, or fails, call `ExternalPaymentMethodResultHandler.onExternalPaymentMethodResult` with the result. This example code just immediately fails: */ ExternalPaymentMethod.onExternalPaymentMethodResult( context, ExternalPaymentMethodResult.failed(displayMessage = "Failed to complete payment"), ) } } ``` ## Optional: Position external payment methods External payment methods aren’t intelligently ranked by Stripe’s smart ordering logic because Stripe doesn’t have context on these payment methods. By default, they appear after Stripe-supported payment methods. Set `PaymentSheet.Configuration.paymentMethodOrder` to explicitly position the external payment method in the Payment Element. The Stripe-supported payment methods following the external payment method are still intelligently ranked. ```kotlin val configuration = PaymentSheet.Configuration.Builder(merchantDisplayName = "Example, Inc.")// Show cards first, followed by external_fawry, followed by all other payment methods .paymentMethodOrder(listOf("card", "external_fawry")) .build() // Present Payment Sheet paymentSheet.presentWithPaymentIntent(paymentIntentClientSecret, configuration) ``` ## Test your integration 1. Go through your checkout flow and verify that the Payment Element displays Fawry. This example configures Fawry in the second position after cards.![The Payment Element when Fawry is added](https://b.stripecdn.com/docs-statics-srv/assets/display-fawry-android.3a16b0565fbf90720db46e0fbcb37c84.png) 1. Choose the Fawry payment method.![The Payment Element when Fawry is selected](https://b.stripecdn.com/docs-statics-srv/assets/select-fawry-android.96f1db81476e2f152cf40bd03e4e9b7f.png) 1. Click the **Pay** button to test your existing Fawry integration. Verify that your integration completes the transaction and that any post-payment actions (for example, displays a confirmation page, success message, or failure message) still work with your Fawry integration. ## Dashboard considerations [PaymentIntents](https://docs.stripe.com/api/payment_intents.md) for transactions processed with an external payment method provider have an `incomplete` status in the Stripe Dashboard. Stripe isn’t involved in external payment method transactions and can’t determine the status of these transactions. If you [collect payment details before creating an Intent](https://docs.stripe.com/payments/accept-a-payment-deferred.md), you won’t see any `incomplete` transactions in the Stripe Dashboard for transactions that were processed with an external payment method provider. ## External payment methods disclaimer You can use the Stripe Mobile Payment Element to show some external payment methods that aren’t supported by Stripe but that you directly integrate with. When customers choose an external payment method, your app completes the transaction instead of the Stripe Mobile Payment Element. You acknowledge that: 1. External payment methods aren’t offered nor supported by Stripe. The operation and support of external payment methods is provided by the external payment method provider. 1. You’re responsible for maintaining a direct integration with the external payment method provider. 1. You need to maintain an agreement with the external payment method provider and are responsible for complying with your agreements with each external payment method provider. 1. You’re responsible for obtaining all necessary rights to use the external payment method provider’s marks and logos within your checkout as described in these docs. 1. Stripe isn’t responsible for the processing of any transactions with any external payment method provider including, for example, any charges, refunds, disputes, settlements or funds flows. 1. You or the external payment method provider are responsible for the completion of the purchase flow after a customer has selected an external payment method, including, for example, the order confirmation and reconciliation of orders. 1. You’re responsible for properly configuring the redirect URL for the external payment method. 1. You must immediately remove any external payment methods in the event your agreements with any external payment method provider terminate or Stripe removes the availability of an external payment method. 1. You’re only permitted to integrate with and present in the Payment Element the external payment methods listed in this guide. 1. You’re solely responsible for making sure that buyers are redirected correctly to their chosen external payment method. ### Ongoing availability of external payment methods Stripe might at any time decide to remove the availability of any payment method as an external payment method. Stripe will notify you of any removal of an external payment method that you’re using, and you must immediately remove the external payment method in your code. Failure to do so will result in the external payment method not rendering to your customers. ## Available external payment methods You can display the following external payment methods. You must use the corresponding external payment method type in your code. | Region | Payment method | External payment method type | | ------------ | ----------------------------------------- | ----------------------------------- | | AMER | Interac | `external_interac` | | APAC | au PAY | `external_au_pay` | | APAC | atone | `external_atone` | | APAC | Touch’n Go | `external_tng_ewallet` | | APAC | ソフトバンクまとめて支払い (Softbank carrier payments) | `external_softbank_carrier_payment` | | APAC | Toss Pay | `external_toss_pay` | | APAC | Laybuy | `external_laybuy` | | APAC | Bank Pay | `external_bank_pay` | | APAC | auかんたん決済 (au easy payments) | `external_au_easy_payment` | | APAC | BitCash | `external_bitcash` | | APAC | Azupay | `external_azupay` | | APAC | d払い (d-barai) | `external_dbarai` | | APAC | FamiPay | `external_famipay` | | APAC | GCash | `external_gcash` | | APAC | GrabPay Later | `external_grabpay_later` | | APAC | MoMo | `external_momo` | | APAC | NET CASH | `external_net_cash` | | APAC | Octopus | `external_octopus` | | APAC | Paidy | `external_paidy` | | APAC | PayPay | `external_paypay` | | APAC | PlanPay | `external_planpay` | | APAC | ペイジー (Pay-easy) | `external_pay_easy` | | APAC | 楽天ペイ (Rakuten Pay) | `external_rakuten_pay` | | APAC | メルペイ (Merpay) | `external_merpay` | | APAC | WebMoney | `external_webmoney` | | APAC, Europe | Shopback Pay | `external_shopback_pay` | | Europe | Aplazame | `external_aplazame` | | Europe | Bizum | `external_bizum` | | Europe | Divido | `external_divido` | | Europe | Fonix | `external_fonix` | | Europe | Iwocapay | `external_iwocapay` | | Europe | KBC | `external_kbc` | | Europe | Nexi Pay | `external_nexi_pay` | | Europe | Oney | `external_oney` | | Europe | Payconiq | `external_payconiq` | | Europe | PayPo | `external_paypo` | | Europe | Sofinco | `external_sofinco` | | Europe | Postepay | `external_postepay` | | Europe | PostFinance | `external_postfinance` | | Europe | Scalapay | `external_scalapay` | | Europe | TrueLayer | `external_truelayer` | | Europe | Walley | `external_walley` | | Europe | YounitedPay | `external_younited_pay` | | Global | LINE Pay | `external_line_pay` | | Global | paysafecard | `external_paysafecard` | | Global | Samsung Pay | `external_samsung_pay` | | Global | Sezzle | `external_sezzle` | | LATAM | Dapp | `external_dapp` | | LATAM | PicPay | `external_picpay` | | MEA | Tabby | `external_tabby` | | MEA | Benefit | `external_benefit` | | MEA | Fawry | `external_fawry` | # React Native > This is a React Native for when platform is react-native. View the full page at https://docs.stripe.com/payments/mobile/external-payment-methods?platform=react-native. React Native apps don’t support external payment methods.