twilio/twilio-video-app-react

The request body is undefined unless we add bodyParser or express.json

Safiya-B opened this issue · 0 comments

Question
Hi,
I just wanted to note that I had this error appear when I ran the server locally :

Screenshot 2023-08-16 at 19 55 57

I found out it was caused by the req.body that was undefined, so I fixed it by adding the express.json() middleware in the index.ts file.
Additional context
Screenshot 2023-08-16 at 19 59 30

Was there another way to make it work without adding the middleware?

Thank you for the app, it is very helpful 👍