How do I update shipping in the popup when using onShippingAddressChange()
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I've implemented my own checkout process for my site some time ago which has only a handful of products.
I'm just using a static page with some JS that handles my cart/products.
A US customer contacted me and told me he can't order from my site and he got this error: "Your order can't be shipped to this address"
I checked the SDK documentation and discovered that onShippingChange() was now deprecated and after migrating to onShippingAddressChange() that error was gone.
What I don't get is the correct workflow for handling the address/shipping fee change.
In my onShippingAddressChange() callback I use data.shippingAddress.countryCode to lookup the shipping costs for the selected address and update the cart on my page accordingly, this part works.
But the price in the popup stays the same.
How do I update the total price in the popup?
I tried to return actions.buildOrderPatchPayload() with a shippingOptions item but that had no effect.
Any ideas/example code?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Did you figure this out? I've spent two days trying to solve a similar issue with not being able to refresh the order price in the PayPal window. I've called the order patch successfully from Postman which updates the actual value, but the displayed value does not change until I reload the PayPal window.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sadly no. Currently I have to charge the same shipping cost for EU and non EU countries 😠
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- Selected Shipping Method amount not updating to cart for card payment in SDKs
- How can I have orders marked as shipped in Shopify be updated as shipped in PayPal? in Braintree Client-side Integration (JS, iOS, Android SDKs)
- Compliance violation. flag based on the account origin ? in Sandbox Environment
- Sandbox isnt working in REST APIs
- Could not create PayPal Buttons in PayPal Payments Standard