{"id":21319463,"url":"https://github.com/zoom/zoom-cohere-chatbot-sample","last_synced_at":"2025-07-29T00:37:31.359Z","repository":{"id":258274901,"uuid":"869081182","full_name":"zoom/zoom-cohere-chatbot-sample","owner":"zoom","description":"The Zoom-Cohere-Chatbot integrates Cohere's AI with Zoom Team Chat, creating an intelligent assistant for users within Zoom conversations. It leverages Cohere's language capabilities to provide context-aware responses to user queries on various topics, enhancing team communication and productivity.","archived":false,"fork":false,"pushed_at":"2024-10-07T22:26:31.000Z","size":443,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-22T11:23:16.428Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/zoom.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}},"created_at":"2024-10-07T17:26:09.000Z","updated_at":"2024-10-16T16:03:17.000Z","dependencies_parsed_at":"2024-10-18T08:36:04.668Z","dependency_job_id":"5eb0535e-686c-4180-8dfd-f9c3f9d94279","html_url":"https://github.com/zoom/zoom-cohere-chatbot-sample","commit_stats":null,"previous_names":["zoom/zoom-cohere-chatbot-sample"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zoom%2Fzoom-cohere-chatbot-sample","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zoom%2Fzoom-cohere-chatbot-sample/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zoom%2Fzoom-cohere-chatbot-sample/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zoom%2Fzoom-cohere-chatbot-sample/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zoom","download_url":"https://codeload.github.com/zoom/zoom-cohere-chatbot-sample/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243800302,"owners_count":20349989,"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","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":"2024-11-21T19:42:00.836Z","updated_at":"2025-03-15T22:27:40.684Z","avatar_url":"https://github.com/zoom.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Zoom-Cohere-Chatbot\n\nThis project integrates Cohere's AI with Zoom Team Chat, creating an intelligent chatbot that can assist users directly within their Zoom conversations. The bot leverages Cohere's advanced language understanding and generation capabilities to provide helpful responses to user queries on a wide range of topics.\n\n## What the Chatbot Does\n\n- Responds to user messages in Zoom Team Chat using Cohere's AI.\n- Maintains conversation history for context-aware responses.\n- Can be used in direct messages or invoked in group chats and channels.\n- Provides helpful information, answers questions, assists with tasks, and engages in discussions on various topics.\n\n## Prerequisites\n\nBefore you can use this chatbot, you'll need the following:\n\n- Node.js (version 12 or later)\n- A Zoom account\n- A Cohere AI account\n\n## Setup\n\nFirst, clone the repository:\n\n```bash\ngit clone https://github.com/zoom/zoom-chat-cohere.git\ncd zoom-chat-cohere\n```\n\nNext, install the required Node.js packages:\n\n```bash\nnpm install\n```\n## Configuration\n\nYou need to set up your environment variables. Create a `.env` file in the project root and add the following variables:\n\n``` bash\nZOOM_CLIENT_ID=your_zoom_client_id\nZOOM_CLIENT_SECRET=your_zoom_client_secret\nZOOM_BOT_JID=your_zoom_bot_jid\nZOOM_WEBHOOK_SECRET_TOKEN=your_zoom_webhook_secret_token\nCOHERE_API_KEY=your_cohere_api_key\n```\n\nTo obtain these variables:\n\n- For Zoom variables (ZOOM_CLIENT_ID, ZOOM_CLIENT_SECRET, ZOOM_BOT_JID, ZOOM_WEBHOOK_SECRET_TOKEN, ZOOM_VERIFICATION_CODE), refer to the [Zoom App Marketplace guide on creating a Team Chat app](https://developers.zoom.us/docs/team-chat-apps/create/).\n\n- For the COHERE_API_KEY, you can obtain it from your Cohere account dashboard.\n\n## Running the Application\n\nTo start the application:\n\nnode index.js\n\nThe application will run on `http://localhost:4000/` by default, but you can set a different port by changing the `PORT` variable in your `.env` file.\n\n## Usage\n\n1. In your Zoom Team Chat App's Credentials section, go to the Local Test or Submit page depending on which environment you are using (Development or Production), and click \"Add\".\n\n2. After authorizing, you will be redirected to Zoom Team Chat and see a message from the chatbot:\n\n   \"Greetings from Zoom-Cohere-Chatbot!\"\n\n3. To use the bot, type a message in the chat like this:\n\n   \"Tell me about the history of San Jose, California\"\n\n4. The response from the bot will look like this:\n\n   [AI-generated response about history of San Jose, California]\n\n   ![Query Example](/images/Image%201.png)\n\n5. The bot remembers context from previous messages:\n\n   ![Context Example](/images/image%202.png)\n\n6. If you want to use the bot in a chat or a channel, you can invoke the bot with a \"/\" command:\nExample:\n   `/cohere-bot Tell me about the history of San Francisco`\n## Key Functions\n\nOur codebase includes several important functions that drive the chatbot's functionality:\n\n- `handleZoomWebhook` (src/zoomWebhookHandler.js): This function processes incoming webhook events from Zoom. It handles different event types, including bot notifications, installations, and uninstallations. For message events, it triggers the Cohere API call.\n\n- `callCohereAPI` (src/cohere.js): This function is responsible for interacting with the Cohere API. It prepares the conversation history, sends the user's message to Cohere, and processes the AI-generated response. It also manages the conversation history for context-aware responses.\n\n- `getChatbotToken` (src/zoomAuth.js): This function obtains an authentication token from Zoom, which is necessary for sending messages back to the Zoom chat. It uses the client credentials flow for secure authentication.\n\n- `sendChatToZoom` (src/sendChatbotMessage.js): After receiving a response from Cohere, this function sends the AI-generated message back to the Zoom chat. It formats the message and uses the Zoom API to deliver the response to the correct chat or channel.\n\nThese functions work together to create a seamless flow from receiving a user message in Zoom, processing it with Cohere's AI, and sending the response back to the user in Zoom Team Chat.\n\n\n## License\n\nThis project is licensed under the MIT License:\n\nMIT License\n\nCopyright (c) \n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzoom%2Fzoom-cohere-chatbot-sample","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzoom%2Fzoom-cohere-chatbot-sample","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzoom%2Fzoom-cohere-chatbot-sample/lists"}