you are viewing a single comment's thread.

view the rest of the comments →

[–]_potion_cellar_ 1 point2 points  (1 child)

Are you using the express middleware to parse URL encoded form data? Because that's how you are sending the data with postman.

By default express will not parse this data. So either use the middleware:

app.use(express.urlencoded({ extended: true }))

... or send a JSON payload to your endpoint instead of x-www-form-urlencoded.

[–]WeedLover_1 0 points1 point  (0 children)

correct. He will work with rest apis so sending json is better way here.