yellowcab/test-api.js
2022-04-24 21:24:23 -04:00

25 lines
619 B
JavaScript

console.log("Testing YellowCab's Internal API");
const ext = require("./internal-api");
console.log("\nTesting user `tacohitbox` on Last.fm");
ext.get("last", "tacohitbox", function(err, resp) {
if (err) {
console.log("There was an error.", err);
process.exit(1);
} else {
console.log("Response:", resp);
console.log("Testing user `tacohitbox` on Librebrainz");
ext.get("listenbrainz", "tacohitbox", function(err, resp) {
if (err) {
console.log("There was an error.", err);
process.exit(1);
} else {
console.log("Response:", resp);
}
})
}
});