🤖 Discord Bot API Test Page

🔑 API Key (Global)

Enter your API key once - it will be used for all authenticated requests below.

1. Health Check Test

Test if the API server is responding (no authentication required)

2. List Guilds (Servers)

Get all Discord servers the bot is currently in

3. Send Direct Message

Send a DM to a Discord user

4. Send Channel Message

Send a message to a Discord channel

5. Send DM with Embed

Send a rich formatted embed via DM

Capital LAN Purple=11250687, Red=16711680, Blue=255, Green=65280, Gold=15844367

6. Send Channel Message with Embed

Send a rich formatted embed to a channel

7. Edit Message

Edit an existing message or embed (bot must have sent the original message)

Tip: Copy the message ID from the response when you send a message

8. Read Single Message

Fetch a single message from a channel by ID

Tip: Copy message ID from any previous API response

9. Read Messages from Channel

Fetch recent messages from a channel

Fetches recent messages from a channel. Leave limit empty to use default (50).

10. Role Management

Add or remove a role from a Discord user

11. Create Role

Create a new role in a Discord server

Common colors: Red=16711680, Blue=255, Green=65280, Purple=10181046, Gold=15844367

12. List Guild Roles

Get all roles in a Discord server

13. List User Roles

Get all roles for a specific user in a server

📋 API Endpoints

Base URL:

HTTP API Endpoints:
GET /health - Health check (no auth)
GET /api/guilds - List all guilds
POST /api/dm - Send direct message (supports embeds)
POST /api/channel - Send channel message (supports embeds)
PATCH /api/message/:channelId/:messageId - Edit message/embed
POST /api/role - Add/remove role
POST /api/roles/:guildId - Create new role
GET /api/roles/:guildId - List guild roles
GET /api/roles/:guildId/:userId - List user roles

Discord Slash Commands:
/purge <count> - Bulk delete messages (Admin only, 1-100)