App reviews, troubleshooting, and recommendations
I'm working on Shopify Remix, but the API POST call is not working on the extension side. However, the same API call works fine on the admin side. I've attached my code below. Can you suggest a solution?
Response
Bad request
No host provided
Hello!
Sorry, where is the code you've attached? 😶
this is my code
In the attached file indicated at the end:
" this is an error show "
"Request URL:"
"https://viral-hms.myshopify.com/apps/proxy/notify"
"Request Method:"
"POST"
"Status Code:"
"400 Bad Request"
""
"Response"
"No host provided"
It seems that the URL configured to be proxied by Shopify is wrong or the destination address is not right.
I'd start checking those values.
My API URL is correct, but it's giving a 400 error. If the API URL is not correct, it should throw a 404 error. Sometimes I get a 500 error, and sometimes I get a 400 error. Please guide me a little more.
And on the admin side, when I make the call, it works perfectly fine, but on the frontend (extension side), the API is not working
I think I've faced a similar problem but not with the remix framework, just with Javascript and React, when delivering requests from the extension to the backend.
You said that on the admin side is working but not on the extension side, so you are using the same path for the call, right?
As you can see the error is complaining about the "host". This parameter is expected for the Shopify middleware that authenticates the session. But from the proxy, this process is different (at the moment I faced the problem)
In my case, to avoid this problem, I used different base-paths for admin requests, and proxy requests: "/api" and "/api_proxy/". So the middleware for "admin-request" does not try to authenticate the request from the extensions.
Nevertheless, incoming requests from the proxy must include another different middleware o method to validate its origin.
Check this doc: https://shopify.dev/docs/api/shopify-app-remix/v2/authenticate/public/app-proxy
Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025Shopify and our financial partners regularly review and update verification requiremen...
By Jacqui Mar 14, 2025