Questions tagged [slack-api]

Slack is a real-time messaging, archiving and search tool for modern teams. Use this tag for programming questions related to the Slack API including the Web API, the RTM API and the Events API.

Slack is a real-time messaging, archiving and search tool for modern teams.

Use this tag for programming questions related to the Slack API including the Web API and the Events API.

Read more about the Slack API here.

2911 questions
14
votes
3 answers

Retrieve full email address from string

I'm currently building a Slack bot using Laravel, and one of the features is that it can receive an email address and send a message to it. The issue is that email addresses (e.g bob@example.com) come through as…
James
  • 15,754
  • 12
  • 73
  • 91
14
votes
5 answers

Slack Webhook - Getting Invalid_Payload

I am attempting to set up a webhook to Slack, but am getting an Error message of "Invalid_Payload" I've looked through Stack, Slack, and Github... but cant' find the answer I seek. "CustomLink" in there for privacy, actual link is begin…
KJ Carlson
  • 215
  • 1
  • 2
  • 11
14
votes
2 answers

Is a Slack channel id unique across teams?

Is a Slack channel/group/im/mpim id unique across different teams? In other words, can two teams have channels with the same id? I read the docs, searched on Google and here on SO, but could not get confirmation if channel IDs are unique or not.
Rafa Viotti
  • 9,998
  • 4
  • 42
  • 62
13
votes
2 answers

How do I post a bulleted list using the slack api

Background I am trying to use the slack bolt jdk along with the following dependencies: // Slack bolt SDK implementation("com.slack.api:bolt:1.8.1") implementation("com.slack.api:bolt-servlet:1.8.1") …
Arnab Datta
  • 5,356
  • 10
  • 41
  • 67
13
votes
2 answers

How to display validation errors about non-input blocks in Slack modals

Question I have a Slack modal with a section block containing an input element. When a user submits my modal without entering a value in this input, how do I communicate that error to the user? My attempt #1: respond with a validation error Slack's…
Gabriel Deal
  • 935
  • 1
  • 8
  • 19
13
votes
2 answers

slack chat.postMessage vs. incoming webhook?

I am trying to send messages from several outer sources to a specific channel, which is private and belongs to myself only. The username should be the name of source, not my ID. I found there are two ways to do such a similar function: Incoming…
ShanChe Wu
  • 315
  • 2
  • 8
13
votes
3 answers

How to access Slack's Interactive Message request payload parameter?

I would like to access the payload parameter sent by Slack to Interactive Message Request Url when a user clicks on a button in one of these messages. How do I do this?
ypicard
  • 3,593
  • 3
  • 20
  • 34
12
votes
2 answers

open slack links in different chrome profiles (users)

let say I have two chrome user, one of them is logged in with my work account and another one is logged as my personal account. I logged in my GitHub/StackOverflow etc accounts with my personal accounts in chrome personal account . in the work user,…
Yuseferi
  • 7,931
  • 11
  • 67
  • 103
12
votes
6 answers

Slack API invalid_block

I'm building a simple slack bot and I am playing with the checkboxes element. When I return the following from my API in a JSON response to a slash-command I get an error failed with the error "invalid_blocks", however, when I put this in the…
Ben Flowers
  • 1,434
  • 7
  • 21
  • 49
12
votes
0 answers

How to use the type "expandable" correctly?

Question How to use the type "expandable" correctly? Description I have a batch that runs every hour and sends some stats to our slack. Each JSON output can be quite large and I'm looking for a way to have it collapsable/expandable. I was playing…
kemicofa ghost
  • 16,349
  • 8
  • 82
  • 131
12
votes
0 answers

Intentionally collapsing long messages with Slack API

I'm using the Slack API to send messages to channels using blocks. Some of these messages consist of quite a few blocks and are quite long, occasionally reaching nearly a full vertical screenful. Normally, long messages are automatically collapsed…
Daniel
  • 6,595
  • 9
  • 38
  • 70
12
votes
1 answer

We had some trouble connecting error when submitting slack dialog (Slack API)

I am building a slack app connected with a Symfony application that uses slash commands and dialogs as UI to create new users, accounts and projects and store them in a database. I use a slash command to trigger a dialog with input fields and store…
12
votes
2 answers

Dialogflow Slack integration app_mention not working

I was successfully able to integrate Dialogflow chatbot as an APP in Slack and it is accessible to chat using the APP tab. However, for it to respond to messages in channels by mentioning like @bot hello I realized that I have to add the app_mention…
Seif Sgayer
  • 268
  • 2
  • 13
12
votes
4 answers

Jenkins / Slack integration

I need to configure Jenkins to send notification on our Slack channel #builds. I configured the Jenkins CI integration in Slack. As a result, I have a token "abcdefgh666", and when I expand the "Setup instructions", I can see our team domain is…
Antwane
  • 20,760
  • 7
  • 51
  • 84
12
votes
2 answers

How do you make a Redirect URI for a Slack App?

I'm trying to create a Slack App (see here), but I'm having incredible difficulty with how to create a Redirect URI. Slack states the following: You must specify at least one redirect URL for OAuth to work. If you pass a URL in an OAuth request,…
Chris
  • 5,444
  • 16
  • 63
  • 119