For discussing the development and usage of Checkout UI extensions, post-purchase extensions, web pixels, and POS UI extensions
I have followed the tutorial here to create an Upsell App using the new Post-Purchase Checkout Extension. I am able to get the page to load after payment, but the Changeset functions applyChangeset and calculateChangeset are both returning 500 Internal Server Errors from Shopify's APIs (see image).
Has anyone else encountered these errors? I am wondering if this is a bug since the API is quite new and still in the works. This is currently affecting my app development so I would appreciate any insight about how to fix this.
Solved! Go to the solution
This is an accepted solution.
Hi Lucas,
We identified the issue, and it should be fixed now.
Thank you for reporting it, and please let us know if you find any other issue.
Cheers!
To learn more visit the Shopify Help Center or the Community Blog.
I'm experiencing the same problem. Did you find solution?
I'm also facing Internal server issue while applyChangeset call.
This is an accepted solution.
Hi Lucas,
We identified the issue, and it should be fixed now.
Thank you for reporting it, and please let us know if you find any other issue.
Cheers!
To learn more visit the Shopify Help Center or the Community Blog.
Hi Denis,
Thanks for your reply on this issue.
I have tried calculateChangeset and applyChangeset functions now.
I'm facing the same error (500 - Internal server error) on calculateChangeset, new error (400 - unprocessed) on applyChangeset. I have attached a screenshot of the errors below for your reference.
Note - Package version that I'm currently using is
Hi! Can you post what you're passing to both methods when calling them, please?
To learn more visit the Shopify Help Center or the Community Blog.
Hi Denis,
I just found out that I'm passing wrong inputs to the functions. Now it's working.
Thank you for your support.
Edit: RESOLVED. Was calling
await calculateChangeset({newChanges});
instead of calling:
await calculateChangeset({changes: newChanges});
****************************************************
Hi, I am still getting a 400 error for calculateChangeset. See below for a screenshot of the changes I'm passing and the error I'm getting.
Can you please let me know what the fix for this was? I'm currently getting the "400 - Changes must be supplied" error. Thanks!
Hi Denis
I am getting what appears to be this exact error in my post puchase checkout when I call the applyChangeset method. See below:
Do you have any pointers or ideas on how to fix it?
Cheers
Liam
I figured out the problem... The payload I encoded in the JWT token has "escaped" JSON as I was using the .to_json method in Rails.
I changed it to payload.as_json and it works fine now!
Happy to help anyone else using Rails if they have problems.
This was working fine since about 2 weeks ago, then I started experiencing this error today, nothing changed in the code, the error is happening for the applyChanges function. Does anyone experience the same thing. I think this is an internal issue from Shopify.
Hi yes I am experiencing the same issue now. My extension was working fine and now all of a sudden it has stopped.
Let me know if you find a resolution, otherwise I guess we have to wait for Shopify to fix it...
Yeah, I guess so. Please I want to ask, since you are also working on a Post-purchase extension, how do you test the extension? Right now, I am using the Chrome developer's extension but I am looking for a cleaner way to test it. Do you have any idea how we can deploy this extension and test it on a development store?
@mr-easy @liamhey you are right, I've just identified an issue affecting post-purchase extensions. The team will have a look at it, but at this point we will need to wait until Monday, unfortunately.
I will update you as soon as I can. Thank you for reporting it!
To learn more visit the Shopify Help Center or the Community Blog.
@denislins thanks for the update! Looking forward to the fix.
@mr-easy I too am using the chrome extension... However this works with my development store so that is how I have been testing it so far.
We shipped a fix earlier today, and everything appears to be working on our side. Could you please confirm it's working on your side as well?
To learn more visit the Shopify Help Center or the Community Blog.
@denislins Yeah, I just checked it and it's working as normal. Thanks.
By the way, please do you know how to test the post purchase extension on a development store without using the Google Chrome or Firefox extension provided by Shopify.
It's possible to test it without the extension by just appending the same values the extension appends to the url yourself. However, I must say it's something I don't suggest, if you can avoid - the extension makes that process much easier.
To learn more visit the Shopify Help Center or the Community Blog.
Oh, I see, thanks.