A bot created to replace the official Bitbucket Cloud bot for Webex, which has been sunsetted. This bot listens to events from Bitbucket and sends notifications to a Webex room.
- Receives webhook events from Bitbucket
- Sends formatted messages to a Webex room
- Uses markdown for message formatting
- Node.js (v14 or later recommended)
- npm (or yarn)
- A Webex bot token
- A Webex room ID
- A Bitbucket repository with webhooks configured
- Clone the repository:
git clone https://github.com/Ralkage/webex-bitbucket-cloud-bot.git
cd webex-bitbucket-cloud-bot
- Install dependencies:
npm install
- Create a .env file in the root directory of the project and add your Webex bot token and room ID:
WEBEX_BOT_TOKEN=your_webex_bot_token
WEBEX_ROOM_ID=your_webex_room_id
- Install
ngrok
if you haven't already. ngrok is a tool that creates a secure tunnel to your local server, allowing external services to access it. You can download ngrok from ngrok's website or install it using a package manager like Homebrew:
brew install ngrok
- Start your local server:
npm start
- Expose your local server to the internet using
ngrok
. In a new terminal window, run:
ngrok http 3000
This will provide you with a public URL (e.g., http://your-ngrok-url.ngrok.io) that you can use to configure Bitbucket webhooks.
- Configure Bitbucket webhooks to point to the
ngrok
URL. Go to your Bitbucket repository settings and add a new webhook with the URL provided byngrok
(e.g.,http://your-ngrok-url.ngrok.io/webhook
).
Feel free to fork the repository and submit pull requests. Please ensure that your code adheres to the existing coding style and includes tests where applicable.
This project is licensed under the MIT License - see the LICENSE file for details.
Christian Lopez (Ralkage)