Basic Node and Express - Get Data from POST Requests

Tell us what’s happening:
Test 1 : Your API endpoint should respond with the correct name
Test 2 : Your API endpoint should respond with the correct name

Your project link(s)
https://boilerplate-express.almerrafi.repl.co

solution: boilerplate-express - Replit

Your browser information:

User Agent is: Chrome

Challenge: Basic Node and Express - Get Data from POST Requests

Any error log at your replit console?

Why did you edit the server.js file when it clearly says not to?

Revert server.js
https://github.com/freeCodeCamp/boilerplate-express/blob/main/server.js

Remove the app.listen code from myApp.js and add back the module.exports = app; export.

no my error in web freecodecamp

  1. Put the export at the bottom of the file.

  2. You remove the middleware you added in the previous challenge. Add it back.

  3. The response object should contain the data you get from req.body, just like how you did it in the query parameters challenge but using req.body.