Definition-retrieving Discord Bot
The Greek Goddess of wisdom takes on a new job as a definition-retrieving Discord Bot.
Define a word with !define <word>
.
!define [flag] <word>
.-n
: noun-v
: verb-adj
: adjective-adv
: adverb!def
Get an example of a word with !example <word>
.
!example [flag] <word>
.-n
: noun-v
: verb-adj
: adjective-adv
: adverb!ex
Play pronunciation of a word with !pronounce <word>
.
!say <word>
Show the above information with !help
.
Pre-requisites:
Clone this repository.
In the root directory create .env
with the following format, replacing placeholders with corresponding tokens:
discordBotToken=DISCORD_BOT_TOKEN_HERE
oxfordAppID=OXFORD_APP_ID_HERE
oxfordAppKey=OXFORD_APP_KEY_HERE
lang=OXFORD_SOURCE_LANGUAGE_ID_HERE
If lang is not provided, the default is “American English.”
npm install
then npm start
. Congratulations, your bot is online!If you want to develop a feature or bug fix, please create a pull request. Before creating a pull request, please read the following:
npm run lint
and npm run lint:fix
. lint
will report errors, and lint:fix
will automatically correct some errors.