Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## 1.0.15-beta.0 — 2026-11-17

### Docs

- Slack app: each alert and audit picks its own channel, colleagues who hold the permission can approve a change (made as them), and a held thread says whose question it is; the Slack incoming-webhook setting is gone. (#1020)

## 1.0.14-beta.0 — 2026-11-16

### Features
Expand Down
3 changes: 1 addition & 2 deletions docs/admin/settings-and-security.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,9 @@ All dashboard-editable settings are organization-scoped. Deployment-wide behavio
| `session_ttl_secs` | `86400` | Dashboard session lifetime; accepted range is 60 seconds to 30 days. |
| `otp_ttl_secs` | `600` | OTP and magic-link lifetime; accepted range is 60–1800 seconds. |
| `alerts.email_default_recipients` | `[]` | Default recipients when an alert email channel does not override them. |
| `alerts.slack_default_webhook` | empty | Default Slack incoming-webhook URL. |
| `alerts.webhook_default_url` | empty | Default generic JSON webhook URL. |
| `alerts.webhook_signing_secret` | empty | HMAC-SHA256 key used for the `X-AgentEye-Signature` header; reads are masked. |
| `alerts.enabled_channels` | email, Slack, webhook | Organization-wide channel kinds that alert rules may dispatch. |
| `alerts.enabled_channels` | email, Slack, webhook | Organization-wide switch for email and generic webhook delivery. Slack is not gated here: each alert or audit opts in by naming the channel the [Slack app](/reference/slack) posts in. |
| `default_user_permissions` | `standard` | Named permission set preselected for new invitations. |

`allowed_sign_ins` is a filter, not a grant: a person must already be an organization member. Use an empty list to allow every member; the bare value `*` is rejected. Alert URLs must use HTTPS except for loopback development addresses.
Expand Down
10 changes: 9 additions & 1 deletion docs/reference/slack.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,22 @@ The first time you ask, the app works out which member you are:

One thread is one conversation. Colleagues can mention the app in the same thread, and it answers each of them with their own permissions. Only the person who started the thread continues it without a mention.

The app answers one question per thread at a time. If someone else mentions it while a question is still running or waiting on its card, the app tells them privately whose question it is and suggests starting a new thread. If the person who asked writes again instead of answering their card, the card is cancelled and the new message is answered.

When the answer is data, the app posts a chart or a table with a link to open it in Failproof AI.

## Approve changes

Every change the assistant makes shows **Approve** and **Cancel** buttons first, and Slack asks once more before **Approve**. Only the person who asked can answer them, the buttons expire after 5 minutes, and the change is made with that person's permissions.
Every change the assistant makes shows **Approve** and **Cancel** buttons first, and Slack asks once more before **Approve**. The buttons expire after 5 minutes.

Anyone in the conversation who holds the permission the change needs can answer the card, not only the person who asked. The change is made as whoever approves it: with their permissions, and recorded under their name. Someone without that permission who clicks is told privately that they can't make the change, and the card stays open for someone who can.

From Slack, the assistant can change saved queries and dashboards, evaluations, alerts, audits, issues, and policies, and suggest code fixes, each if you hold the permission. It can't change API keys, users, or settings.

## Alerts and audit reports

Once a workspace is connected, the app posts alerts and audit reports itself. Each alert and each audit picks its own channel: turn on **post to slack** when you create or edit it in Failproof AI and choose the channel, or ask the assistant in Slack, which asks whether to post in the current channel or another one. Invite the app to a channel first with `/invite`; private channels work too.

## Link previews

Failproof AI issue, session, and evaluation links pasted in Slack unfurl into cards on hosted Failproof AI Cloud. A card shows only what the person who triggered it can see. Links to a self-hosted address don't unfurl, though cards in the assistant's own answers still appear.
Expand Down
2 changes: 2 additions & 0 deletions fp-cloud-cli/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ moved the version here automatically; nothing has landed against `0.0.4b0` yet.
Add entries as changes merge — this section becomes the GitHub Release body when
it ships.

- An alert's Slack channel shows as the channel it posts in (`#ops`), not "default webhook": Slack alerts are posted by the Slack app in a channel each alert names. (#1020)

## 0.0.3 — 2026-11-16

**Stable release.** The `0.0.3b1` line the `bump` job opened after `0.0.3b0` is cut stable
Expand Down
19 changes: 9 additions & 10 deletions fp-cloud-cli/fp_cli/output.py
Original file line number Diff line number Diff line change
Expand Up @@ -3639,31 +3639,30 @@ def _alert_trigger_body(kind: str, spec: Optional[dict]):

def _is_default_key(key: Optional[str]) -> bool:
"""A channel setting-key is on the org DEFAULT when it's absent or ``alerts.``-prefixed
(e.g. ``alerts.slack_default_webhook``); a bare entered key/url is CUSTOM."""
(e.g. ``alerts.webhook_default_url``); a bare entered key/url is CUSTOM."""
return key is None or str(key).startswith("alerts.")


def _alert_channels_body(channels: Optional[list]):
"""Parse ``channels`` into ``(all_default, table)``: one row per channel with a DIM ITALIC
``default …`` descriptor where it inherits org settings, or the entered value in GREEN where
overridden (mixed supported). Empty ``[]`` → the full default set (slack/webhook/email)."""
overridden (mixed supported). Empty ``[]`` → the default set (webhook/email). Slack is
always the alert's own channel, posted by the Slack app — there is no default webhook."""
dim_it = lambda s: Text(s, style=f"italic {theme.TEXT_DIM}") # noqa: E731
rows = []
all_default = True
if not channels:
rows = [("slack", dim_it("default webhook")),
("webhook", dim_it("default url + signing secret")),
rows = [("webhook", dim_it("default url + signing secret")),
("email", dim_it("default recipients"))]
else:
for ch in channels:
kind = str(ch.get("kind", "?"))
if kind == "slack":
key = ch.get("webhook_setting_key")
if _is_default_key(key):
desc = dim_it("default webhook")
else:
desc = Text(str(key), style=theme.SUCCESS)
all_default = False
# The channel the Slack app posts in: by name, else by id.
name = str(ch.get("channel_name") or "").lstrip("#")
where = f"#{name}" if name else str(ch.get("channel_id") or "")
desc = Text(where, style=theme.SUCCESS) if where else dim_it("no channel picked")
all_default = False
elif kind == "webhook":
desc = Text()
url, sec = ch.get("url_setting_key"), ch.get("secret_setting_key")
Expand Down
15 changes: 10 additions & 5 deletions fp-cloud-cli/tests/test_output.py
Original file line number Diff line number Diff line change
Expand Up @@ -1002,7 +1002,7 @@ def test_render_alert_show_metric_threshold(capsys):
assert "fire when error_count > 50 over 15m" in out
assert "environment = production" in out and "event_type = tool_call" in out
assert "window 1" in out and "min breaches 1" in out and "checks every 5m" in out
assert "channels · default" in out and "slack" in out and "default webhook" in out
assert "channels · default" in out and "webhook" in out and "default url" in out and "default webhook" not in out
output.configure(no_color=True, quiet=False)


Expand Down Expand Up @@ -1060,14 +1060,19 @@ def test_render_alert_channels_custom_and_default():
# empty → all defaults
all_def, _ = output._alert_channels_body([])
assert all_def is True
# a custom slack + default email → not all-default
mixed, _ = output._alert_channels_body([
{"kind": "slack", "webhook_setting_key": "my_slack_url_entered"},
# a slack channel is always the alert's own pick → not all-default
mixed, table = output._alert_channels_body([
{"kind": "slack", "channel_id": "C0123456789", "channel_name": "ops"},
{"kind": "email", "recipients": None},
])
assert mixed is False
from rich.console import Console
console = Console(record=True, width=80)
console.print(table)
assert "#ops" in console.export_text()
# alerts.-prefixed key counts as default
defaulted, _ = output._alert_channels_body([{"kind": "slack", "webhook_setting_key": "alerts.slack_default_webhook"}])
defaulted, _ = output._alert_channels_body([{"kind": "webhook", "url_setting_key": "alerts.webhook_default_url",
"secret_setting_key": "alerts.webhook_signing_secret"}])
assert defaulted is True
output.configure(no_color=True, quiet=False)

Expand Down
Loading