{"id":31261538,"url":"https://github.com/firecrawl/ai-discord-bot","last_synced_at":"2025-09-23T10:11:02.118Z","repository":{"id":193352886,"uuid":"688630813","full_name":"firecrawl/ai-discord-bot","owner":"firecrawl","description":"Easily build and deploy your AI Discord Bot with Mendable","archived":false,"fork":false,"pushed_at":"2024-07-14T11:37:43.000Z","size":22,"stargazers_count":12,"open_issues_count":3,"forks_count":4,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-08-18T19:02:28.308Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.mendable.ai/integrations/discord","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/firecrawl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-09-07T18:57:57.000Z","updated_at":"2025-08-10T19:01:53.000Z","dependencies_parsed_at":"2023-09-07T21:45:10.597Z","dependency_job_id":"f8b5afce-68bf-4729-81c3-91ff2403f620","html_url":"https://github.com/firecrawl/ai-discord-bot","commit_stats":null,"previous_names":["mendableai/mendable-discord","firecrawl/ai-discord-bot"],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/firecrawl/ai-discord-bot","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firecrawl%2Fai-discord-bot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firecrawl%2Fai-discord-bot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firecrawl%2Fai-discord-bot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firecrawl%2Fai-discord-bot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firecrawl","download_url":"https://codeload.github.com/firecrawl/ai-discord-bot/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firecrawl%2Fai-discord-bot/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276555369,"owners_count":25663232,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-23T02:00:09.130Z","response_time":73,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-09-23T10:10:59.634Z","updated_at":"2025-09-23T10:11:02.099Z","avatar_url":"https://github.com/firecrawl.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Mendable AI Discord Bot\n\nThis is a Discord bot that uses the Mendable API to answer questions and provide sources for the answers. It creates a new thread for each question asked and stores the history of the conversation.\n\n## Features\n\n- Starts a new thread for each question asked.\n- Uses the Mendable API to answer questions and provide sources.\n- Stores the history of the conversation.\n\n## Setup\n\n1. Clone this repository.\n2. Install the required dependencies with `npm install`.\n3. Create a `.env` file in the root directory of the project and add the following environment variables:\n    - `MENDABLE_API_KEY`: Your Mendable API key.\n    - `DISCORD_TOKEN`: Your Discord bot token.\n    - `BOT_ID`: Your Discord bot ID.\n4. Run the bot with `node index.js` or `npm run start`.\n\n## Usage\n\nTo ask a question, mention the bot followed by your question. For example:\n\n```\n@MendableAI How to create a Mendable AI Discord Bot?\n```\n\nThe bot will create a new thread, answer the question, and provide sources for the answer.\n\n## Dependencies\n\n- `discord.js`: A powerful library for interacting with the Discord API.\n- `dotenv`: A zero-dependency module that loads environment variables from a `.env` file into `process.env`.\n\n\n## Creating a Discord Application and Getting the Necessary Tokens and Bot ID\n\n1. **Create a Discord Application**\n    - Go to the [Discord Developer Portal](https://discord.com/developers/applications).\n    - Click on the `New Application` button.\n    - Give your application a name and click `Create`.\n\n2. **Create a Bot for the Application**\n    - Click on the `Bot` tab on the left side of the application page.\n    - Click on the `Add Bot` button on the right and confirm by clicking `Yes, do it!`.\n\n3. **Get the Bot Token**\n    - Still on the `Bot` tab, find the `Token` section.\n    - Click on `Copy` to copy the bot token. This is your `DISCORD_TOKEN`.\n\n5. **Get the Bot ID**\n    - Go to the `General Information` tab on the left side of the application page.\n    - Find the `Application ID` section and click `Copy`. This is your `BOT_ID`.\n\n6. **Invite the Bot to Your Server**\n    - Go to the `OAuth2` tab on the left side of the application page.\n    - In the `Scopes` section, select `bot`.\n    - In the `Bot Permissions` section, select the permissions your bot needs.\n    - Copy the generated URL and open it in your web browser to invite the bot to your server.\n\n5. **Get the Bot ID**\n    - Right click on the bot name and select `Copy ID`. This is your `BOT_ID`.\n\n\n## Deploying to Railway\n\nWith [Railway](https://railway.app) you can deploy your bot in less than a minute. To do so, follow these steps:\n\n1. Create a new Railway project.\n2. Connect your GitHub repo that contains the bot's code.\n3. Insert your environment variables in the `Environment Variables` section of the project settings.\n4. That's it! Railway will automatically deploy your bot and keep it running.\n\n## Contributing\n\nPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirecrawl%2Fai-discord-bot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirecrawl%2Fai-discord-bot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirecrawl%2Fai-discord-bot/lists"}