Change the username of incoming webhook message
See original GitHub issueI use the following code snippet to send notification message to an incoming webhook URL:
from slack_sdk.webhook import WebhookClient
webhook_url = "https://hooks.slack.com/services/T0..."
webhook_sync = WebhookClient(webhook_url)
response = webhook_sync.send(text="Test notification")
My question is how can I specify the username of that message like Gitlab does on its slack notification settings? I couldn’t find any parameter to do that.
Issue Analytics
- State:
- Created a year ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Override Incoming Webhook Username - Mattermost Forum
What determines an incoming webhook's username? Can this be changed?
Read more >Sending messages using Incoming Webhooks - Slack API
Incoming Webhooks are a simple way to post messages from apps into Slack. Creating an Incoming Webhook gives you a unique URL to...
Read more >Incoming WebHook and dynamic user-name/channel
If you want to send message to any channel with a custom username your best option is to use the Slack API with...
Read more >Get User email in Action Card in Incoming Webhook in Teams ...
Users in the Teams channel can do the actions with this message. (Add a comment, Set a due date, Change status). I want...
Read more >Incoming Webhooks — Mattermost 4.0 documentation
(Optional) Configure the Enable integrations to override usernames option to allow external applications to post messages under any name. If not enabled, the ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@agn-7 Thanks for the reply. So, in this case,
as I mentioned above, you can still create the legacy webhook, which supports username and other parameters. It’s not recommended from a long-term maintenance perspective, but it works for now (and at least until the sunset of legacy custom integrations although we haven’t decided anything on the timeline).
Since we don’t have anything further to share on this topic, let us close this issue now. Thanks again for writing in!
@agn-7 Utilizing a Web API such as chat.postMessage is completely different from Incoming Webhooks. Please refer to the document for more details: https://slack.dev/python-slack-sdk/web/index.html