Using Node.js with Import.io
Dependencies
npm i csvtojson request
- Go to the Integrate tab for your Import.io extractor
- Copy the CSV from the last successful run endpoint
- Replace the endpoint into the below with the CSV endpoint
const request = require('request');
const csv = require('csvtojson');
const fetch = uri => {
request(uri, (error, response, body) => {
csv({
output: 'json'
}).fromString(body)
.then(data => {
console.log(data);
});
}
};
fetch();