This is a simple discord bot buit to interact with some discord users.
- Pulumi installed (see instructions).
- Nodejs 16.x or latest installed see instructions.
- An AWS account.
- An Discord account.
- A discord bot created on Discord developer portal
- Git installed (see instructions)
You need to create an environment config in the following way.
DISCORD_TOKEN='yourDiscordToken'
DISCORD_PUBLIC_KEY='yourDiscordPublickey'
DISCORD_APPLICATION_ID='yourDiscordApplicationId'
DISCORD_SERVER_ID='yourDiscordServerId'
And save it as any or all of the following files within the folder /environmentConfigs
develop.env
production.env
lambdadevelop.env
Your default environment is develop.env
and default deployed environment would be lambdadevelop.env
- Clone this repo using SSH or Github Cli (guide).
- Navigate to the cloned repo/folder(uglyBot) using a terminal or shell and run the following.
npm install
npm run build
npm run start
cd pulumi
npm install
pulumi up
- Review and accept the deployment. (note that this will automatically create required services and resources in AWS lambda).
- Copy the URL on the output
apiGatewayEndpointUrl
and append it withdiscordEvents
. Example:https://example.execute-api.us-east-1.amazonaws.com/stage/discordEvents
and set theINTERACTIONS ENDPOINT URL
on your application to the URL you just constructed. - Add your discord bot to one of your servers. (make sure the server ID is the same as the one you specified on Configuration).
- Try the command
/info
on your server.
npm run coverage
npm run updateReadmeCoverage
Distributed under the MIT License. See LICENSE.txt for more information.
Project Owner - Dasith Kuruppu