On-Call API › Slack
List Slack channels
GET/api/v1/slack/channels
The connected workspace's channels, for choosing where an escalation step or the default channel posts.
Permission (API-key scope): oncall:escalation:write.
Authorization
bearerAuth(oncall:escalation:write)apiKeyHeader(oncall:escalation:write)
Responses
200
The channels.
dataarray of SlackChannel requiredShow SlackChannel properties
idstringnamestringprivateboolean
successboolean required
401
No API key was sent, or it is unknown, revoked or expired (UNAUTHORIZED).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
403
The key lacks the scope this endpoint needs (FORBIDDEN).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
409
Slack is not connected (SLACK_NOT_CONNECTED).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
429
Too many requests (RATE_LIMITED). Wait Retry-After seconds.
Retry-AfterintegerSeconds to wait.
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
500
Something went wrong on EvoHub's side (INTERNAL_ERROR). Retry later.
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
502
Slack did not return the list (SLACK_ERROR).
errorobject requiredcodestring requiredMachine-readable code. Branch on this.messagestring requiredHuman-readable explanation.
Example request
curl -X GET 'https://evohub.io/api/v1/slack/channels' \
-H 'Authorization: Bearer <TOKEN>'