Challenge: Making POST and GET Requests to a Public REST API
Explore how to make GET and POST requests to a public REST API using Express and node-fetch in a MEAN stack setup. Learn to fetch data and post new data correctly while logging results for verification.
We'll cover the following...
We'll cover the following...
Challenge description for making a GET request
This part of the exercise is implemented by taking the following steps:
-
Install and import both the
expressandnode-fetchpackages. -
Configure the
PORTandapp.listen()in Express. -
Make a GET request using the fetch npm package to the REST API below from ...