I'm getting this dialog
implementation 'com.paypal.sdk:paypal-android-sdk:2.16.0'
val intent = Intent(this, PayPalService::class.java)
intent.putExtra(PayPalService.EXTRA_PAYPAL_CONFIGURATION, config)
startService(intent)
private var config =
PayPalConfiguration()
.environment(PayPalConfiguration.ENVIRONMENT_SANDBOX)
.clientId(AppConstants.getPayPalClientID())
val payment = PayPalPayment(
BigDecimal(7),
"USD",
"abcd",
PayPalPayment.PAYMENT_INTENT_ORDER
)
payment.invoiceNumber(getting this from my backend)
val intent = Intent(this, PaymentActivity::class.java)
// send the same configuration for restart resiliency
// send the same configuration for restart resiliency
intent.putExtra(PayPalService.EXTRA_PAYPAL_CONFIGURATION, config)
intent.putExtra(PaymentActivity.EXTRA_PAYMENT, payment)
startActivityForResult(intent, 0)
The above-implemented code is for Paypal payment,
Is the above-implemented code is correct or not
below provided my error
for the above code, I'm getting the below exception
E/paypal.sdk: request failure with http statusCode:404,exception:
2021-01-28 17:16:05.886 7263-10006/{package name} E/paypal.sdk: Exception parsing server
response
org.json.JSONException: End of input at character 0 of
at org.json.JSONTokener.syntaxError(JSONTokener.java:460)
at org.json.JSONTokener.nextValue(JSONTokener.java:101)
at com.paypal.android.sdk.cw.m(Unknown Source:7)
at com.paypal.android.sdk.fm.d(Unknown Source:0)
at com.paypal.android.sdk.ci.a(Unknown Source:21)
at com.paypal.android.sdk.cm.a(Unknown Source:58)
at com.paypal.android.sdk.cq.onResponse(Unknown Source:45)
at okhttp3.RealCall$AsyncCall.execute(RealCall.java:174)
at okhttp3.internal.NamedRunnable.run(NamedRunnable.java:32)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)
2021-01-28 17:16:05.887 7263-10006/{package name} E/paypal.sdk: request failed with server
response:
2021-01-28 17:16:05.890 7263-7263/{package name} E/paypal.sdk: INTERNAL_SERVER_ERROR
please give the solution for this,
anyone have a Paypal mobile SDK integration, please give the blog
question from:
https://stackoverflow.com/questions/65936836/while-paypal-integration-i-entered-email-and-password-im-getting-login-fa 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…