How to request a page in NodeJS?



  • I wonder how to request a page using NodeJS. Basically, I need to make a request to a webservice that provides location data based on the informed cep and from the given answer (which comes in json format), handle the data and perform some operations. I'm a node beginner and I don't know how to do that. I'm using the 4.x express framework in the project. I thank everyone for their collaboration!



  • you can use the https://github.com/axios/axios or https://github.com/visionmedia/superagent to make requests in any API from within your nodejs code




Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2