Slack return a 400 no_text when webhook called
Issue description
I'm trying to send Slack notifications on Gitlab events using gitlab webhooks and Slack apps webhooks
Each time Gitlab trie to send a notification, it receive a 400 no_text
I've found a similar issue but it's closed: #205571 (closed)
How to reproduce
- On Slack side, create an App, then add a webhook for this App.
I'm not using the Incoming webhooks Slack integration which is deprecated (https://slack.com/apps/A0F7XDUAZ-webhooks-entrants).
- On Gitlab side, I went to my project page then
Settings>Webhook.
- Add a new Webhook
-
You can now test directly from the newly created
Project hook -
Each Slack answer is a
400 no_text
Additional informations
The example given by Slack is working perfectly with the same webhook
$> curl -X POST -H 'Content-type: application/json' --data '{"text":"Hello, World!"}' https://hooks.slack.com/services/[...]/[.....]/[..........]
ok%
I created a file containing the body payload sent by Gitlab to this slack webhook in the file payload.json then executed the same request
$> curl -X POST -H 'Content-type: application/json' --data @payload.json https://hooks.slack.com/services/[...]/[.....]/[..........]
no_text%
The payload.json file is attached to this issue payload.json
The Slack API probably changed when moving from legacy Slack incoming webhooks integration and Slack Apps webhook



