smarkets / react-native-paypal

React Native library that implements PayPal Checkout flow using purely native code
MIT License
118 stars 54 forks source link

valid token from your server #53

Closed weingenious72 closed 3 years ago

weingenious72 commented 3 years ago

in the usage section, I show the line to create client token for Braintree. I checked the Braintree document and don't understand where am I going to put the code for getting the client token.

nzankich commented 3 years ago

Yea, these instructions are a bit ambiguous currently. Going to try and create an example app to give more troubleshooting information

nzankich commented 3 years ago

@weingenious72 ok, I've updated the readme about how to find/generating this token

The fetch should go immediately before requestOneTimePayment or requestBillingAgreement. Wait for the fetch to complete then use the returned token in the react-native-paypal package function

Does that answer your question?

nzankich commented 3 years ago

@weingenious72 going to close this. lmk if you're still having trouble after looking at the readme