I am trying to make a post request from postman to my function https://fra.cloud.appwrite.io/v1/functions/functionid/executions on the same body when i put from the appwrite dashboard sucess and when trying same request from postman i get
Native logs detected. Use context.log() or context.error() for better experience. Failed to parse request body as JSON: SyntaxError: Unexpected end of JSON input at JSON.parse (<anonymous>) at Module.default (file:///usr/local/server/src/function/src/main.js:112:21) at execute (/usr/local/server/src/server.js:220:42) at action (/usr/local/server/src/server.js:237:27) at process.processTicksAndRejections (node:internal/process/task_queues:105:5) at async /usr/local/server/src/server.js:26:5 This is from appwrite logs for the execution with status code 400
Cannot parse what i am doing is Const data = JSON.parse(req.body) in a try and catch block I trying changing it to req.payload but the same problem , what i am doing wrong ??
Recommended threads
- Appwrite Cloud project is paused and nev...
Hi Appwrite Team & Community, I am facing a problem with one of my Appwrite Cloud projects which seems to be identical to the other cases of "paused projects" ...
- Timed out waiting for runtime error
execution id 6a3e0791978712d81ee0 im having issue with appwrite function runtime performance. even after 4gbram and cpu same function sometimes completes in a...
- Project auto-blocked after load testing ...
Hi team 👋 My project has been automatically blocked with the message: "Project is currently blocked — Access to this project is restricted. Contact support if...