in-app-payments-react-native-plugin
in-app-payments-react-native-plugin copied to clipboard
Payment not completed (Apple Pay)
I am trying to make payment through apple pay and in return I am getting this error Payment not completed. I tried using both the testing environment and production environment but facing the same error.
Library version:
- "react-native-square-in-app-payments": "^1.4.0",
Sharing the screenshot of the error which I am facing.
Did you already go through this process: https://github.com/square/in-app-payments-react-native-plugin/blob/master/docs/enable-applepay.md? Specifically the first part where you need to upload the Apple Pay certificate to your Square Developer Dashboard.
If so, what's your Square app id?
Did you already go through this process: https://github.com/square/in-app-payments-react-native-plugin/blob/master/docs/enable-applepay.md? Specifically the first part where you need to upload the Apple Pay certificate to your Square Developer Dashboard.
If so, what's your Square app id?
Yes, I have uploaded the apple pay certificate on Square Developer Dashboard.
Square app id: sandbox-sq0idb-5p2pswXDioJLzsn8zGg5zg
I'm not seeing anything obvious on our side (no logs at all, so it's not even making it to the nonce generation). Can you try a different card and see if you still experience the same error?
I'm not seeing anything obvious on our side (no logs at all, so it's not even making it to the nonce generation). Can you try a different card and see if you still experience the same error?
I have tried the same with the real card as well as test cards but I am facing the same issue.
@StephenJosey any update?
Thanks for confirming. I will escalate on our side to see if we can dig in.
Thanks for confirming. I will escalate on our side to see if we can dig in.
Any luck on this?
Thanks for confirming. I will escalate on our side to see if we can dig in.
Any luck on this?
Hi @StephenJosey, any luck on this?
Apologies for delay. I have not heard back from the team. I'll be sure to update this once I have more information.
@StephenJosey I am also facing the same issue. Any update?
Hi @rajatpillai would you be able to share how you're creating the apple pay request? eg:
await SQIPApplePay.requestApplePayNonce(
{
price: '1.00',
summaryLabel: 'Test Item',
countryCode: 'US',
currencyCode: 'USD',
paymentType: SQIPApplePay.PaymentTypeFinal,
},
@vatsal-gadhiya-searce was able to find this issue was caused by passing UK
instead of GB
and I'm wondering if it's the same issue as you?
Hi @rajatpillai would you be able to share how you're creating the apple pay request? eg:
await SQIPApplePay.requestApplePayNonce( { price: '1.00', summaryLabel: 'Test Item', countryCode: 'US', currencyCode: 'USD', paymentType: SQIPApplePay.PaymentTypeFinal, },
@vatsal-gadhiya-searce was able to find this issue was caused by passing
UK
instead ofGB
and I'm wondering if it's the same issue as you?
const applePayConfig = {
price: totalValue,
summaryLabel: card.name,
countryCode: 'US',
currencyCode: 'USD',
paymentType: SQIPApplePay.PaymentTypeFinal,
};
try {
await SQIPApplePay.requestApplePayNonce(
applePayConfig,
this.onApplePayNonceRequestSuccess,
this.onApplePayNonceRequestFailure,
this.onApplePayEntryComplete,
);
} catch (ex) {
// Handle InAppPaymentsException
}
@StephenJosey The above is the way I am creating an apple pay request.
@StephenJosey it will be great if any team member can come for a screen share call, where he can verify the things and can efficiently debug the issue. I have a deadline and it will be great if I can get support from the Square team.
Thanks
Would you be willing to share a sample project where this issue is occurring? Based on the above code we are not able to replicate, so it seems to be something specific to your project that we aren't able to reproduce. Feel free to reach out to me on our Slack channel for easier communication as well: https://squ.re/2Hks3YE
I have the same issue, this is the error that I'm getting -
{
"code": "USAGE_ERROR",
"message": "Something went wrong. Please contact the developer of this application and provide them with this error code: unexpected",
"debugCode": "apple_pay_nonce_request_unexpected",
"debugMessage": "Square In-App Payments SDK encountered an unexpected error. Please contact Square developer support via https://squareup.com/help/contact"
}
and my configuration to request requestApplePayNonce
const applePayConfig = {
price: '1.00',
summaryLabel: 'Service',
countryCode: 'US',
currencyCode: 'USD',
paymentType: SQIPApplePay.PaymentTypePending,
};
try {
await SQIPApplePay.requestApplePayNonce(
applePayConfig,
this.onApplePayNonceRequestSuccess,
this.onApplePayNonceRequestFailure,
this.onApplePayEntryComplete,
);
} catch (ex) {
// Handle InAppPaymentsException
console.log('Exception', ex);
}
it's happening in "react-native-square-in-app-payments": "^1.4.0", 1.6.0 and 1.7.0
This in my react native info System: OS: macOS 11.4 CPU: (16) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz Memory: 138.25 MB / 16.00 GB Shell: 5.8 - /bin/zsh Binaries: Node: 14.17.6 - /usr/local/bin/node Yarn: Not Found npm: 8.0.0 - /usr/local/bin/npm Watchman: 2021.06.07.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.10.2 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: iOS 15.0, DriverKit 20.4, macOS 11.3, tvOS 15.0, watchOS 8.0 Android SDK: API Levels: 27, 28, 29, 30 Build Tools: 28.0.3, 29.0.0, 29.0.2, 29.0.3, 30.0.2 System Images: android-26 | Google APIs Intel x86 Atom_64, android-27 | Intel x86 Atom_64, android-28 | Intel x86 Atom_64, android-28 | Google APIs Intel x86 Atom_64, android-28 | Google Play Intel x86 Atom, android-28 | Google Play Intel x86 Atom_64, android-28 | Google X86_ARM Intel x86 Atom, android-29 | Google APIs Intel x86 Atom_64, android-30 | Google APIs Intel x86 Atom_64 Android NDK: Not Found IDEs: Android Studio: 4.1 AI-201.8743.12.41.6953283 Xcode: 13.0/13A233 - /usr/bin/xcodebuild Languages: Java: 1.8.0_292 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: ^17.0.1 => 17.0.1 react-native: ^0.64.2 => 0.64.2 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found
Please let me know if you fin the fix for it
Any resolution for this issue? it just started happening to specific customers and I am wondering if you know how to resolve this?
Just to follow up, looks that the certificate on Square admin was removed from me. Not sure if it can help someone else. I don't think it's a Square issue.
@sudzy-group close this issue, please let us know if this is still a problem.
hi @hukid - why did you closed this issue? We have hundreds of merchants complaining about this. The problem is that the certificate is revoked before the expiration time and this causes this issue.
@hukid - can I speak with someone to show them the issue?
@sudzy-group thanks for the quick response! I'll connect you with someone.
Thank you @hukid , looking forward
Hi @sudzy-group are you still seeing this issue?
Closing as we have not gotten a follow up from the developer. Feel free to reopen if you are still facing this issue.