Inspiration Command

This commit is contained in:
Dragon Fire
2021-03-01 18:15:44 -05:00
parent 4e39ec1206
commit 6eab1831e9
3 changed files with 38 additions and 2 deletions
+4 -1
View File
@@ -270,7 +270,7 @@ in the appropriate channel's topic to use it.
## Commands
Total: 607
Total: 608
### Utility:
@@ -407,6 +407,7 @@ Total: 607
* **food:** Responds with a randomly generated food.
* **fox:** Responds with a random fox image.
* **hentai:** Responds with a random hentai image. (NSFW)
* **inspiration:** Responds with a randomly generated inspiration.
* **interesting:** Responds with a random interesting image.
* **light-novel-cover:** Responds with a randomly generated Light Novel cover. (NSFW)
* **lorem-picsum:** Responds with a random image of a certain size.
@@ -1390,6 +1391,8 @@ here.
* eject ([Original "Among Us" Game](https://innersloth.com/gameAmongUs.php))
- [Inside Scanlation](https://www.insidescanlation.com/)
* chi-idea ([Wild Words Font](https://www.insidescanlation.com/etc/the-idiots-guide-to-editing-manga/guide/type/fonts.html))
- [InspiroBot](https://inspirobot.me/)
* inspiration (API)
- [ipify API](https://www.ipify.org/)
* ip (API)
- [iStock](https://www.istockphoto.com/)
+33
View File
@@ -0,0 +1,33 @@
const Command = require('../../structures/Command');
const request = require('node-superfetch');
module.exports = class InspirationCommand extends Command {
constructor(client) {
super(client, {
name: 'inspiration',
aliases: ['inspire', 'inspirobot'],
group: 'random-img',
memberName: 'inspiration',
description: 'Responds with a randomly generated inspiration.',
clientPermissions: ['ATTACH_FILES'],
credit: [
{
name: 'InspiroBot',
url: 'https://inspirobot.me/',
reason: 'API'
}
]
});
}
async run(msg) {
try {
const { text } = await request
.get('https://inspirobot.me/api')
.query({ generate: true });
return msg.say({ files: [text] });
} catch (err) {
return msg.reply(`Oh no, an error occurred: \`${err.message}\`. Try again later!`);
}
}
};
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiao",
"version": "131.1.1",
"version": "131.2.0",
"description": "Your personal server companion.",
"main": "Xiao.js",
"scripts": {