PaySwitcher
  • About PaySwitcher
    • πŸ›’For Online Businesses
    • πŸͺœFor Small & Medium Enterprises
    • 🏒For Enterprises
    • πŸ–₯️For SaaS Providers
    • πŸ›οΈFor E-Commerce Businesses
    • πŸ“¦For Marketplace/Platforms
    • 🏦For Banks & Financial Institutions
  • PaySwitcher Cloud
    • ⚑Quickstart
      • πŸ“₯Migrate from Stripe
        • Web
        • Android
        • iOS
        • React Native
      • πŸ₯—Payment Recipes
        • Use PayPal With Stripe
    • βš™οΈControl Centre Account setup
    • πŸ“¦Integration guide
      • 🌐Web
        • Node And React
        • Customization
        • Error Codes
        • Node and HTML
        • Vanilla JS and REST API Integration
      • πŸ“±Android
        • Kotlin with Node Backend
        • Customization
        • Features
      • πŸ“±iOS
        • Swift with Node Backend
        • Customization
        • Features
      • ⏺️React Native
        • React Native with Node Backend (Beta)
        • Card Widget (Beta)
        • Customization
      • ⏺️Flutter
        • Flutter with Node Backend
        • Customization
      • Headless SDK
      • Payment Methods Management
    • πŸ’³Payment methods setup
      • πŸ’³Cards
      • πŸ“±Wallets
        • Apple Pay
          • Web Domain
          • iOS Application
        • Google Pay
        • PayPal
      • πŸ“†Pay Later
      • 🏦Banks
        • Bank Debits
        • Bank Redirects
        • Bank Transfers
      • πŸͺ™Crypto
      • πŸ”‘Test Credentials
    • πŸ”ŒConnectors
      • πŸ–²οΈAvailable Connectors
        • ACI
        • Adyen
        • Airwallex
        • Authorizedotnet
        • Bambora
        • Bank of America
        • Billwerk
        • Bluesnap
        • Braintree
        • Checkout
        • Coinbase
        • Cybersource
          • Apple Pay
          • Google Pay
        • dLocal
        • Fiserv
        • GlobalPayments
        • GoCardless
        • Klarna
        • Mollie
        • MultiSafepay
        • Nuvei
        • OpenNode
        • Paypal
        • PayU
        • Prophetpay
        • Rapyd
        • Shift4
        • Stripe
        • TrustPay
        • Volt
        • Worldline
        • Worldpay
        • Zen
      • Activate connector on PaySwitcher
      • Test a Payment with connector
    • πŸͺWebhooks
  • Features
    • πŸ”€Payment flows
      • πŸ”Saving payment methods & recurring payments
      • πŸ’΅Payouts
        • βž•Get started with payouts!
        • πŸ”—Process payouts using saved payment methods
        • πŸ›£οΈRoute your payout transactions using Smart Router
        • ♻️Smart Retries in Payout
        • πŸ”—Payout links
      • 0️ 0️ 0️ Zero Amount Authorization
      • πŸ”“Tokenization & saved cards
      • πŸ”—Payment links
      • ⏭️External Authentication for 3DS
      • πŸ’°Manual Capture
      • πŸ›‘Fraud Blocklist
      • πŸ”Subscriptions
      • πŸ”ƒPG Agnostic Recurring Payments
    • πŸ•ΉοΈMerchant controls
      • πŸ›£οΈSmart Router
        • Rule Based Routing
        • Volume Based Routing
        • Default Fallback Routing
      • πŸ›‘οΈFraud & risk management
      • πŸ”ƒSmart retries
      • πŸŽ›οΈAnalytics & operations
      • πŸ“‹3DS decision manager
        • Setup guide
      • πŸ“‹Surcharge
        • Surcharge Setup guide
      • πŸ”Ό3DS Step-up retries
      • 🚩Disputes/Chargebacks Management
      • 🀝Reconciliation
        • Getting Started with Recon
    • πŸ”‘Account management
      • πŸ”’Exporting payments data
      • 🀹Multiple accounts & profiles
      • πŸ›‚Manage your team
    • πŸ›οΈE-commerce platform plugins
      • WooCommerce Plugin
        • Setup
        • Compatibility
        • FAQs
  • SECURITY AND COMPLIANCE
    • πŸ”Overview
    • πŸ’³PCI Compliance
    • πŸ”Data Security
    • πŸ’½GDPR compliance
    • πŸ•΅οΈIdentity and Access Management
  • Learn more
    • 🍑SDK Reference
      • Node
      • React
      • JS
    • πŸ“PaySwitcher Architecture
      • Router
      • Storage
      • A Payments Switch with virtually zero overhead
    • 🌊Payment flows
Powered by GitBook
On this page
  1. PaySwitcher Cloud
  2. Quickstart
  3. Migrate from Stripe

Android

Migrate from Stripe on your android app

PreviousWebNextiOS

Last updated 11 months ago

Migrate from Stripe on your Android app in less than 15 mins!

If you are already integrated with Stripe as your payment processor, we have made migrating to PaySwitcher much simpler for you. And we will be adding quick migration support for more leading payment processors in the near future. And once you migrate, get immediate access to 40+ payment processors and features such as Smart Router, Digital Payments Manager and many more.

Android - Node Backend and Kotlin Frontend

The code from your Stripe integration to be removed and replaced is explained below in a step by step manner.

Step 1: Install PaySwitcher’s SDK and server side dependencies from npm

 $ npm install @payswitcher/payswitcher-node

Step 2: Change the API key on the server side and modify the paymentIntent endpoint from your server side. You can get the API key from page on the dashboard.

// from
const stripe = require("stripe")(your_stripe_api_key);
// to
const stripe = require("@payswitcher/payswitcher-node")(
  "your_payswitcher_api_key"
);

Step 3: Configure your android with PaySwitcher dependency Add the following maven repository to the settings.gradle file

dependencyResolutionManagement {
    repositories {
        google()
        mavenCentral()
        maven {
            url "https://maven.payswitcher.com/release/production/android/maven/1.0.1"
        }
    }
}

Step 4: Replace the dependencies block of your app build.gradle file

// from
implementation 'com.stripe:stripe-android:20.27.3'
// to
implementation 'io.payswitcher:payswitcher-android:1.0.1'

Step 5: Change these imports in your project

// from
import com.stripe.android.PaymentConfiguration;
import com.stripe.android.paymentsheet.PaymentSheet;
import com.stripe.android.paymentsheet.PaymentSheetResult;

// to
import io.payswitcher.PaymentConfiguration;
import io.payswitcher.paymentsheet.PaymentSheet;
import io.payswitcher.paymentsheet.PaymentSheetResult;

Step 6: Add an extra import for PaySwitcher and implement HyperInterface

import io.payswitcher.HyperInterface

class CheckoutActivity : AppCompatActivity(), HyperInterface {

Step 7: Run your application to make a test payment. And verify the status of the transaction on PaySwitcher Dashboard and Stripe Dashboard. Congratulations ! You have successfully integrated PaySwitcher to your payments stack and you now have access to a suite of 40+ payment processors and acquirers.

⚑
πŸ“₯
Developers