# Fix Jenkins-to-Slack connection

XMLWordPrintable

#### Details

• Type: Bug
• Status: Done
• Resolution: Done
• Fix Version/s: None
• Component/s:
• Labels:
None
• Team:
SQuaRE
• Urgent?:
No

#### Description

Since the Jenkins reboot on Monday, it has been unable to post Slack notifications.

The error message is failed to send message: [ok:false, error:token_revoked]

The token in question appears to be SLACK_TOKEN. This corresponds to the Jenkins credential item slack-lsstc-token.

Please fix the Slack interface, perhaps by refreshing this token.

#### Activity

Hide

I switched back to sqrbot xoxb token. I don't think this will work either but at least it might get us back to GET working?

Show
Adam Thornton added a comment - I switched back to sqrbot xoxb token. I don't think this will work either but at least it might get us back to GET working?
Hide

Better news: we generated a new-style token, and KT found docs that it can no longer go in the URL parameters, but Authorization: Bearer $TOKEN seems to work. Show Adam Thornton added a comment - Better news: we generated a new-style token, and KT found docs that it can no longer go in the URL parameters, but Authorization: Bearer$TOKEN seems to work.
Hide
Kian-Tat Lim added a comment -

Followed the pre-existing example for POST requests.

Show
Kian-Tat Lim added a comment - Followed the pre-existing example for POST requests.
Hide
Kian-Tat Lim added a comment -

Reviewed on the PR.

Show
Kian-Tat Lim added a comment - Reviewed on the PR.
Hide
Kian-Tat Lim added a comment -

And it actually works!  (Once I replaced the token with the new app token that Adam gave me.)

Show
Kian-Tat Lim added a comment - And it actually works!  (Once I replaced the token with the new app token that Adam gave me.)

#### People

Assignee:
Kian-Tat Lim
Reporter:
Kian-Tat Lim
Reviewers:
Watchers:
Adam Thornton, Frossie Economou, Kian-Tat Lim