{"size": 380, "ext": "js", "max_stars_repo_path": "website/scripts/delete-index.js", "max_stars_repo_name": "smondet/taquito", "max_stars_repo_stars_event_min_datetime": "2019-09-04T23:49:06.000Z", "max_stars_repo_stars_event_max_datetime": "2019-09-11T20:51:31.000Z", "max_issues_repo_path": "website/scripts/delete-index.js", "max_issues_repo_name": "smondet/taquito", "max_issues_repo_issues_event_min_datetime": "2019-08-05T00:34:13.000Z", "max_issues_repo_issues_event_max_datetime": "2019-09-18T18:06:40.000Z", "max_forks_repo_path": "website/scripts/delete-index.js", "max_forks_repo_name": "smondet/taquito", "max_forks_repo_forks_event_min_datetime": "2019-08-18T20:07:50.000Z", "max_forks_repo_forks_event_max_datetime": "2019-09-13T22:18:08.000Z"}
{"max_stars_count": 3, "max_issues_count": 50, "max_forks_count": 2, "avg_line_length": 22.3529411765, "max_line_length": 54, "alphanum_fraction": 0.7236842105}
require('dotenv').config();

const algoliasearch = require('algoliasearch');

const client = algoliasearch(
  process.env.ALGOLIA_APPLICATION_ID, 
  process.env.ALGOLIA_UPDATE_API_KEY
); 
const index = client.initIndex('taquito');

try {
  index.delete();
  console.log('Successfully deleted index: taquito');
} catch(e) {
  console.log(`Failed to delete Algolia index: ${e}`);
}
