Node REST testing
So far, we have created a GET AWS Lambda request handler, and a POST AWS Lambda handler. The GET requests are fairly simple to test, as we can simply copy and paste the URL into a web browser to execute a GET request. POST handlers, however, need a tool such as Postman in order to construct the correct data packet to send to the server. For the purposes of this exercise, let's use a very simple Node-based program that will issue a GET request to our TypeScript handler, and then issue a POST request.
When developing large-scale applications that use REST endpoints, we often need to use the results of a REST request as input into another REST request. As an example of this, consider an authentication REST endpoint that accepts ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access