What is the issue in the code below? When I click on “Apply,” it processes but then fails to complete.
Topic summary
A user is experiencing issues with a custom Apple Pay button implementation on their Shopify store. When clicked, the button processes but fails to complete the transaction.
Technical Details:
- The user shared custom JavaScript code for handling Apple Pay sessions, shipping rates, and payment completion
- The code appears to fetch shipping rates from Shopify’s API and calculate totals including shipping costs
Current Problem:
- Apple Pay button displays inconsistently on iOS devices (iPhone 16 Pro Max, iPad)
- Most of the time, only the “Buy with Shop” or “Buy It Now” button appears instead
- Issue persists even after theme adjustments and disabling the “Buy with Shop” button
- Testing URL provided: https://brizofan.com/products/test
Troubleshooting Attempts:
- Another user suggested using Shopify’s built-in Dynamic Checkout button instead of custom code
- Verified the issue occurs specifically on iOS devices where Apple Pay should be available
- Multiple devices tested with same inconsistent results
Status: The user has contacted Shopify support, who acknowledged the issue and said they would work on it. Discussion remains open pending support team response.
@ahmer oh sorry for facing this issue
can you please use Shopify Dynamic checkout button its would be great for your store please check this article.
@KetanKumar The Apple Pay button sometimes appears, but most of the time, the “Buy with Shop” button is displayed.
@ahmer yes Apple Pay button show only IOs Device
I am checking this on iOS. On iOS, it sometimes shows the Apple Pay button but always displays the “Buy with Shop” button. I am using an iPhone 16 Pro Max.
@ahmer oh sorry if possible to share video further issue?
I tried adjusting the theme as well, but the issue remains the same. I turned off the “Buy with Shop” button, and now it only shows “Buy It Now,” but the Apple Pay button still doesn’t appear.
@ahmer can you please share your store url
@ahmer i have check my friend iPhone its work
I’ve checked almost 100 times on my brother’s iPhone, my iPhone, and my iPad, but it’s still not showing.
@ahmer oh sorry this that issue can you please just inform these Shopify support team
I already informed them, and they said they would work on it and let me know
@ahmer sounds good so can you please wait support response
