GraphQL + Express server hosted on Netlify returns normally locally but does not show anything in production

I have two applications hosted on Netlify right now: one serves my frontend and one serves my backend. The frontend was made using create-react-app and my backend was created using a Netlify + express + graphql tutorial I found. When I ping the backend from the frontend locally, everything returns fine and I am able to run my queries. When I try this in production, I don’t see anything. My requests say 200, but no response body is returned. I figure it has something to do with my toml file.

frontend: GitHub - nohharri/harrisonnoh-new
backend: GitHub - nohharri/harrisonnoh-express-2

– frontend netlify.toml –
[build]
functions = “functions”
[[redirects]]
from = “/api/"
to = “/.netlify/functions/:splat”
status = 200
[[redirects]]
from = "/express/

to = “https://harrisonnoh-backend.netlify.app/.netlify/functions/server
status = 200
force = true
headers = { X-From = “Netlify”, Access-Control-Allow-Origin = “" }
[[redirects]]
from = "/

to = “/index.html”
status = 200

– backend netlify.toml –
[build]
command = “npm install && npm run build”
functions = “functions”

Hi, The current redirect active is this one:

[[redirects]]
    from = "/express/*"
    to = "https://harrisonnoh-backend.netlify.app/"
    status = 200
    force = true
    headers = { X-From = "Netlify", Access-Control-Allow-Origin = "*" }

So, this URL:

https://<site custom domain here>/express

Is proxied to this URL:

https://harrisonnoh-backend.netlify.app/

We can see that both URLs return the same content and status:

$ curl https://<insert custom domain here>/express
<!DOCTYPE html>
<object
  type="text/html"
  data="/.netlify/functions/server"
  style="width:100%;height:100%;"
>
$ curl https://harrisonnoh-backend.netlify.app/
<!DOCTYPE html>
<object
  type="text/html"
  data="/.netlify/functions/server"
  style="width:100%;height:100%;"
>

Can you give us an example URL on the first site and what URL should be served for the second site being proxied to? With that information we should be able to suggest a redirect that meets those requirements.

So from harrisonnoh.com, I am triggering a backend endpoint to https://harrisonnoh-backend.netlify.app/.netlify/functions/server which works completely fine locally. It returns 200 with the response body: { id: 0 }. In production, it returns 200 but no response body. The first site will proxy /express which goes to https://harrisonnoh-backend.netlify.app/.netlify/functions/server.

Hey there, @nohharri :wave:

Sorry to be slow to respond here. Is this still occurring for you? If so, can you please provide more information about what steps have you been taking to recreate this error?

Thank you!