POST Request Error on netlify function


I have a reactjs app the nodejs server (exposed as netlify function) deployed on the given URL.
Everything works normally in local environment. but when deploying on the netlify I am getting the following error:

@aps08 I’m not sure how you’ve tried to implement it, but as it says, it’s trying to POST to /api/auth/signin and is receiving a 404 because that route does not exist.

Here is the netlify.toml file.

  functions = "server/functions/"
  command = "yarn workspace client build"
  publish = "client/build"
  external_node_modules = ["express"]
  node_bundler = "esbuild"
  force = true
  from = "/api/*"
  status = 200
  to = "/.netlify/functions/api/:splat"

The redirects are working fine in local.

@aps08 I don’t believe the issue is the rewrite, as the direct URL also returns the same 404



Both return