Node.js REST Service Logging - app.js requests

PHOTO EMBED

Fri Apr 14 2023 10:50:48 GMT+0000 (Coordinated Universal Time)

Saved by @mindplumber #javascript #nodejs

{
  "category": "test",
  "routes": ["route1", "route2"]
}
content_copyCOPY

For example, to add a new category called "test" with routes "route1" and "route2", you would send a POST request to `http://localhost:3000/addCategory` with the following request body: After sending this request, you can access the new routes at - `http://localhost:3000/test/route1/info` - `http://localhost:3000/test/route1/warn` - `http://localhost:3000/test/route1/error` - `http://localhost:3000/test/route2/info` - `http://localhost:3000/test/route2/warn` - `http://localhost:3000/test/route2/error`