forked from Supositware/Haha-Yes
Cleverbot!
Signed-off-by: loicbersier <loic.bersier1@gmail.com>
This commit is contained in:
parent
fbd3c4ed33
commit
9fc87f42be
1 changed files with 34 additions and 0 deletions
34
commands/fun/cleverbot.js
Normal file
34
commands/fun/cleverbot.js
Normal file
|
@ -0,0 +1,34 @@
|
|||
const { Command } = require('discord-akairo');
|
||||
const cleverbot = require('cleverbot-free');
|
||||
|
||||
class CleverBotCommand extends Command {
|
||||
constructor() {
|
||||
super('CleverBot', {
|
||||
aliases: ['CleverBot', 'cb'],
|
||||
category: 'fun',
|
||||
clientPermissions: ['SEND_MESSAGES', 'ATTACH_FILES'],
|
||||
args: [
|
||||
{
|
||||
id: 'message',
|
||||
type: 'string',
|
||||
prompt: {
|
||||
start: 'What do you want to say to cleverbot?'
|
||||
},
|
||||
match: 'rest'
|
||||
},
|
||||
],
|
||||
description: {
|
||||
content: 'Talk to cleverbot!',
|
||||
usage: '',
|
||||
examples: ['']
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
async exec(message, args) {
|
||||
cleverbot(args.message).then(response => {
|
||||
return message.channel.send(response);
|
||||
});
|
||||
}
|
||||
}
|
||||
module.exports = CleverBotCommand;
|
Loading…
Reference in a new issue