Notify Chatwork or Slack, when receive pull request notifications from Bitbucket.
- Pull Request on Bitbucket
- Hook post request to your server will occur.
- This application receives the request, and post notification messages to the chat. (Chatwork or Slack)
- Created
- Merged
- Updated
- Declined
- Comment created (on the pull request page)
- PHP 5.3+ with cURL with composer
- Access token of Chatwork, if you want notification to that.
- Access token of Slack, if you want notification to that. (xoxp-xxxxx)
- If you want to create a token to access to the page of Slack API.
- Bitbucket repository with administrator right.
- Get source code from GitHub, either using Git, or by downloading directly.
- Copy the source files to public directory in your server.
- Setup correct permissions
chmod -R 777 tmp
- Adjust token in your config file.
- for the Chatwork
cp config/chatwork.json.default config/chatwork.json
vim config/chatwork.json
- for the Slack
cp config/slack.json.default config/slack.json
vim config/slack.json
- for the Chatwork
- Plugin install with composer. (You need to install composer.)
composer install
- Please set the following post destination url in chat work your account setting page. (room_id is chatwork room id.)
- Sample pull request post hook url (for Chatwork):
- Sample pull request post hook url (for Slack):
Key | Description | Example for Chatwork | Example for Slack |
---|---|---|---|
destination_service | Post destination service name. | chatwork | slack |
room_id | Post destination. | 1000000000 | #bitbucket, C1234567890 |
- If you include the # to the channel name, please URL-encoded.
- Example:
#bitbucket
->%23bitbucket
- Example:
- 創作メモ帳
- 創作メモ帳 - Slackへのプルリクエスト通知に対応しました : Japanese document is here