💡Http Example

Example API request with javascript

const axios = require('axios').default;

var options =  {
headers: {
        'Authorization': 'TOKEN'
    }
}

axios.get('https://api.fluxpoint.dev', options)
  .then(function (response) {
    console.log('Success');
    var data = JSON.parse(response);
    console.log(data.message);
  })
  .catch(function (error) {
    console.log(error);
  });

Last updated