Skip to content

Introduction

cordless lets you build a production Discord bot without running a bot server. It’s a Python framework that deploys your bot as an AWS Lambda function: no process to keep alive, just code that wakes up when Discord sends an interaction.

Discord sends a POST request to your bot’s URL every time a user runs a command or clicks a button. With cordless, that URL is a Lambda Function URL by default (or an API Gateway endpoint if you want a custom domain), backed by a Lambda function either way. The function wakes up, handles the interaction, and goes back to sleep.

For interactions that take longer than Discord’s 3-second response window, cordless automatically invokes a second “worker” Lambda asynchronously and keeps the user’s message updated as work completes.

  • No idle cost: you pay only when interactions happen
  • No ops: no EC2, no containers, no uptime monitoring
  • Scales automatically: handles one interaction or ten thousand

A typical cordless bot looks like this:

my-bot/
├── lambda_function.py # entrypoint
├── cogs/
│ └── hello.py # command handlers
└── cordless.toml # deploy config