Slack · Search messages — Finds messages with Slack's own search — as you — runs a Slack search and gives each message it finds as an item, for the steps after it to work through.
Who can do this
Workspace Admins and Editors, on every plan.
Before you start
- A Slack connection in this workspace — see Connect Slack.
- Your own Slack account connected beside it. Slack keeps search to people, not apps, so this step always works as the person who added it.
Steps
- Select +, then in Apps select Slack, then Search messages.
- In Connection, choose your Slack connection.
- Read the note under the settings. "Acts as Rohan Mehta (@rohan) in Slack." means you are ready. "Acts as you. Connect your own Slack account once — until then the step fails." means select Connect my Slack account first; Slack asks you, then brings you back to the workflow.
- In Search for, type the search — Slack's own search: words, in:#channel, from:@someone. For example quote in:#sales-leads. Use
{{ }}for values from earlier steps. - Under Order, choose Newest first (the default) or Best match.
- In Return at most, the number of messages — One item per message. 100 at most. 20 by default.
- Select Run this step.
Output
One item per message found:
| Field | What it is |
|---|---|
ts |
The message's timestamp. |
text |
What it says. |
user |
The Slack name of who wrote it. |
channel |
The channel's id. |
channelName |
The channel's name. |
permalink |
A link to the message in Slack. |
Good to know
- It finds what you can see. The search runs as your own Slack account, so it covers the channels and conversations you are in — not only the ones the app is in.
- The step acts as whoever added it. If Asha Raghunathan adds it, it searches as her, and fails until she has connected her own account.
- Steps after it run once per message. With nothing found, the steps after it do not run for that item.
- Return at most takes 1 to 100.
If something goes wrong
| What you see | Why | What to do |
|---|---|---|
| … has not connected their own account for Post as me. They connect it once from the connection on Connections. | The person the step acts as has no own account connected. | They select Connect my Slack account in the connection's panel on Connections. |
| Search messages works as the person who added it, and nobody is set — the step came from a template or a file. Change any of its settings and it works as you. | The step came into the workflow without a person — from a template or an imported file. | Open the step and change any setting, for example Return at most. It then works as you. |
| The Slack account this step acts as no longer lets Bizomate in — Bizomate was removed from it in Slack. Its owner connects it again from the Slack connection on Connections. | Bizomate was removed from that person's own Slack account. | They select Connect my Slack account in the connection's panel. |
| Search for is empty when the step ran — … | The search came out empty. | Check the values it reads. |
| Slack no longer accepts the connection. Reconnect it on Connections. | Slack stopped accepting the connection. | Select Reconnect on the connection. |
| Slack is asking Bizomate to slow down. The step will work again in a minute. | Too many searches at once. | Wait a minute. |