What this does
A fleet attached to a Slack channel answers when someone mentions theagentsfleet app in that channel. The fleet reads the thread, runs once, and posts its answer as a reply in the same thread.
Slack sometimes delivers one mention twice. The second delivery starts no second run.
Before you begin
Connect Slack to your workspace at Settings → Integrations. See Connect a provider for the full procedure. Invite theagentsfleet Slack app to the channel. The app receives mentions only in channels it belongs to.
Find the channel identifier (ID) in Slack. Open the channel’s details and copy Channel ID from the bottom of the About tab. It starts with C for a public channel or G for a private one.
Steps
-
Add a
mentiontrigger for the channel to the fleet’s Definition.<CHANNEL_ID>is the channel ID you copied. The entry goes in thetriggerslist underconfig["x-agentsfleet"], beside the fleet’s other triggers:In a chat, you can ask for the same trigger in words, such as “answer mentions in Slack channel<CHANNEL_ID>”. Author a fleet covers the chat and the Definition file.channelsholds exactly one channel ID. One fleet answers in one channel. To answer in a second channel, save a second fleet. -
Review the setup and check that it carries the one
mentiontrigger, then save it.<DRAFT_ID>,<NAME>, and<DIGEST>come from the review output.In the dashboard, check Your fleet setup and choose Save fleet. -
Mention the app in the channel and ask your question.
The fleet reads the thread you asked from and replies in that thread.
-
Start with the fleet’s name when the channel has more than one fleet.
Case does not matter. A
:or,right after the name is ignored.
repository_access: write in its Definition. The table shows which fleet answers a mention.
A fleet whose Definition declares
repository_access: write answers only when a mention names it.
From one mention it can open at most one draft pull request (PR).
It cannot merge the PR, mark it ready for review, or change a workflow.
The channel’s own fleet
agentsfleet creates one fleet per channel the first time a mention reaches no attached fleet or needs a notice. Its name is slack-channel-<TEAM_ID>-<CHANNEL_ID>, in lower case.
This fleet answers from a model with no tools and no network access. Its budget is daily_nanos: "1000000000", so it spends at most 1 dollar a day. When you ask for something it cannot reach, it tells you to set up a fleet in agentsfleet chat with a mention trigger for this channel.
Its memory belongs to the channel, and no other fleet reads it. It also posts the channel’s notices.
Verify it works
- Mention the app in the channel.
- Check that a reply from the fleet appears in the same thread.
- Open the fleet in the dashboard. Its trigger card reads Chat mention with the channel ID.
-
List the fleet’s events.
<FLEET_ID>comes fromagentsfleet list.
Common problems
A notice replaces an answer whenagentsfleet cannot pick one fleet. Each notice names the next step.
A notice appears 30 to 60 seconds after the mention.
The fleet reads the first message of the thread and the latest 19 replies. It cuts each message at 2,000 characters and the whole thread at 16,000.
In a private channel, the fleet sees only your mention. The Slack app cannot read private channel history. The fleet also answers from the mention alone when Slack does not return the thread within 1.5 seconds.
If Slack loses its reply to a posted answer,
agentsfleet checks the thread before it posts again. The answer appears once. In a private channel agentsfleet cannot check, so the answer can appear twice.
A fleet you save under the name slack-channel-<TEAM_ID>-<CHANNEL_ID> with settings of its own is never used as the channel’s own fleet. While it holds that name, a mention that needs the channel’s own fleet starts no run. Rename or delete that fleet.
A fleet you save under that name with the channel fleet’s exact runtime settings counts as the channel’s own fleet. It answers in that fleet’s place.
A mention from a bot, an edited message, or the app’s own reply starts no run.
A mention from a Slack workspace that is not connected to an agentsfleet workspace starts no run. Connect Slack again from Settings → Integrations.
Remove or undo
To detach a fleet from the channel, remove itsmention trigger and apply the change.
- Open the fleet in the dashboard and choose Setup → Edit fleet.
- Ask the chat to remove the Slack mention trigger.
- Check that the trigger is gone from Update fleet setup, then choose Save changes.
agentsfleet chat --fleet <FLEET_ID> --setup-revision <SETUP_REVISION> --model <MODEL_REF>. <SETUP_REVISION> is the setup_revision field that agentsfleet --json fleet show <FLEET_ID> prints. Ask for the change, then run /review and /apply.
To remove it, run agentsfleet kill <FLEET_ID> and then agentsfleet delete <FLEET_ID>.
Between the two commands, the channel fleet is killed, and a mention that needs it gets no answer. A channel fleet you stop instead of killing answers with the paused notice until you resume it.