Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

superagent vs axios

const axios = require('axios');

(async () => {
  try {
    const response = await axios.get('https://the-one-api.dev/v2/book?api_key=MY_KEY')
    console.log(response.data.name);
  } catch (error) {
    console.log(error.response.body);
  }
})();
Source by learn.vonage.com #
 
PREVIOUS NEXT
Tagged: #superagent #axios
ADD COMMENT
Topic
Name
2+7 =