mirror of
https://gitea.com/mcereda/oam.git
synced 2026-02-09 05:44:23 +00:00
2.7 KiB
2.7 KiB
Slack
TL;DR
Setup
brew install --cask 'slack'
mas install '803453959'
Usage
# Send notifications to channels
curl -X 'POST' -H 'Content-type: application/json' \
--data '{"text": "Hello, World!"}' \
'https://hooks.slack.com/services/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'
Add custom emoji
Check out slackmojis for some common reactions.
- Go to https://{{org-name}}.slack.com/customize/emoji.
- Select Add Custom Emoji.
- Upload the image. Supported formats: GIF, JPG, PNG.
- Give it a name.
Give aliases to existing emojis
- Go to https://{{org-name}}.slack.com/customize/emoji.
- Select Add Alias.
- Choose the image.
- Give it an alias.
Apps
Direct links:
Incoming webhooks
Refer Sending messages using incoming webhooks and Setting Up Slack Webhook URL Simplified 101.
-
Enable Incoming Webhooks for a Slack app.
Features → Incoming Webhooks → Activate Incoming Webhooks. -
Create a new Webhook URL and authorize it (or request authorization for it).
-
Install the app in the workspace.
-
Send a test request to the webhook.
curl -X 'POST' -H 'Content-type: application/json' \ 'https://hooks.slack.com/services/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' --data '{"text": "Hello, World!"}'