EcoBot/commands/cat.js

12 lines
335 B
JavaScript
Raw Permalink Normal View History

2021-11-22 23:37:00 +00:00
module.exports = {
api: {
name: "cat",
description: "Sends a random image of a cat"
},
run: (int, client, index) => {
const axios = require("axios").default;
axios("https://api.thecatapi.com/v1/images/search").then(res => {
int.reply({embeds: [{title: "Cat", image: {url: res.data[0].url}, color: 0xFFC0CB}]});
});
}
}