Stripe integration in android and create token

后端 未结 4 539
暗喜
暗喜 2021-01-03 15:19

I want to integrate stripe in android and test the code with publishable key. I want to create token after successful transaction with the card params any suggested code.

4条回答
  •  醉话见心
    2021-01-03 15:59

    You should not make a charge inside the Android app. The client (here your App), should only get a Stripe token, then send this token to your backend (your server), and then use this token to create a charge with stripe.

    You must not create a charge client side as it is not secure : your secret key should not be inside the app, as it won't be secret anymore.

    This is the reason why the lib stripe-android does not have the charge class : it is not meant for that. The stripe-java lib is meant to be used on a java server.

提交回复
热议问题