How to Make API Requests with Request-Promise in Node.js

One task you’ll encounter often in Node.js is making HTTP requests to an external API from a server. Request-promise, a Promise-based wrapper for the popular request library, helps us do just that. This in-depth reference tutorial shows you how to use an NPM package called request-promise, which is an extended version of the request library with added Promise support.

By the end of this tutorial, you should be able to:

  • Learn how to install request-promise from NPM
  • Make GET, POST, PUT, PATCH, and DELETE calls to external APIs using request-promise
  • Configure your requests with headers, query-strings, bodies, and more options
  • Understand how to handle errors when making HTTP requests using request-promise
Log in or Sign up to view the complete tutorial.

Sign in with your Osio Labs account
to gain instant access to our entire library.

Data Brokering with Node.js