## TL;DR

The Slack incoming webhook URL the agent posts to was deactivated (app reinstalled, workspace settings changed, or the webhook was revoked), so alert posts fail. Create a new incoming webhook in the Slack app configuration, update the agent's webhook URL, and send a test alert. Webhook URLs are secrets with a lifecycle; the agent must handle rotation.

## Error

```text
cost agent's slack alert failed  -  incoming webhook deactivated
```

## Steps

1. Confirm the failure: the agent log shows the webhook post failing. Expected: the post error indicates an invalid or deactivated webhook.
2. In the Slack app's configuration, check the incoming webhooks section. Expected: the old webhook shows as deactivated or is missing.
3. Create a new incoming webhook for the alert channel. Expected: a fresh webhook URL is issued.
4. Update the agent's configuration with the new URL (prefer a secrets store over hardcoding). Expected: the agent holds the current URL.
5. Send a test alert and verify it lands in the channel. Expected: the alert posts successfully.

## When to use

- Slack alerts from the cost agent stop arriving.
- The webhook post fails as deactivated or invalid.
- The Slack app was reinstalled or reconfigured.

## When not to use

- The Slack API rejects with permission errors (an app-scope problem).
- The channel was archived or deleted.
- The agent never had a working webhook (initial setup).

## Tool compatibility

Slack incoming webhooks (current 2026 releases). Applies to agents posting alerts via webhooks.

### Variant phrasings

### slack alerts silently stopped

The webhook was likely deactivated. Check and replace it.

### "invalid webhook" on alert post

Create a fresh incoming webhook and update the agent.

### webhook worked until the app reinstall

Reinstalls revoke webhooks. Reissue after any reinstall.

## Why it happens

Incoming webhooks are long-lived URLs that Slack can deactivate on app reinstalls, workspace policy changes, or security events. The agent holds the URL as configuration and has no signal that it died until posts fail. Treating the webhook URL as a rotatable secret (stored centrally, monitored for failures, reissued on events) prevents silent alert loss.

## Provenance

Resolved from the public thread: https://vectle.com/posts/pst_mwQq0FYkdk3g2SlYnhln-g
