How-To
Table of Contents
Get the hook
In a direct chat with @ThookBot use command /start
In a public/private group add before @ThookBot as a member and then use /start
command.
In a public/private channel add before @ThookBot as a administrator, then use /start@ThookBot
command.
Then you will receive your personal webhooks directly from the bot. The endpoint is so composed:
https://thook.altr.dev/hooks/{name_of_service}/{unique_path}
In a bot response you can find a secret key
useful for authenticate any call.
Keep all data for you only and so delete the bot’s message from a group/channel once you’ve copied the data.
Services
Generic
Netlify
GitLab
GitHub
Generic
https://thook.altr.dev/hooks/generic/xxxxxxxxxxx
You can POST
any text or JSON and it will be directly sent as a notification in the dedicated linked Telegram chat, group or channel.
Example:
curl -X POST \
"https://thook.altr.dev/hooks/generic/{unique_path}" \
-H 'Content-Type: text/plain' \
-H 'X-Webhook-Signature: {your_secret}' \
--data-raw "Hello 👾"
Netlify
https://thook.altr.dev/hooks/netlify/xxxxxxxxxxx
This webhook is specific for Netlify.
Supported events:
On your Telegram chat you will receive a decorated notification like this:
or this:
To insert a webhook you must go to Netlify under Deploy Notification
, choose Outgoing Webhook
and fill the modal like this:
Use your Netlify generated endpoint
and secret key
GitLab
https://thook.altr.dev/hooks/gitlab/xxxxxxxxxxx
This webhook is specific for GitLab.
Supported events:
- Push events
- Tag events
- Issue events
- Confidential issue events
- Merge request events
- Wiki page events
- Pipeline events
- Job events
On your Telegram chat you will receive a decorated notification like this:
or this:
To insert a webhook you must go to GitLab project under Settings
, choose Webhooks
and fill form like this:
Use your GitLab generated endpoint
and secret key
. Select your interested events
GitHub
https://thook.altr.dev/hooks/github/xxxxxxxxxxx
This webhook is specific for GitHub.
Supported events:
- Push events
- Check Run events
- Check Suite events
- Page Build events
- Star events
- Watch events
- Fork events
- Create events
- Delete events
- Repository Vulnerability Alert events
- Pull Request events
- Coming soon [ Issue, Sponsorship ]
On your Telegram chat you will receive a decorated notification like this:
or this:
To insert a webhook you must go to your GitHub project, then Settings
in the menu and choose Webhooks
. Now Add Webhook
botton and fill form like this:
Use your GitHub generated endpoint
and secret key
. Select application/json
in Content Type
and in Which events would you like to trigger this webhook?
section you can choose every single event clicking Let me select individual events.
Example on Travis CI
In this example: a ReactJs site was built and deployed on GitHub Pages.
Then result is notified by travis_to_thook.sh
who call Thook
.
Enjoy by @ThookBot !