Integration delivery
Outgoing event subscriptions use a durable queue in workspace.db. Each matching
delivery commits with its workspace event, then runs outside the user's request.
Failures retry eight times with increasing delays, in event order for each
subscription and in parallel across different subscriptions. Pending work resumes
when the server restarts. A successful receiver may see the same event again if the
server exits after its HTTP response but before recording completion, so receivers
must deduplicate by the stable event_id.
Stopping the server cuts off any delivery, slash command or button call still waiting on an app, rather than waiting out its timeout. A delivery cut off that way is not counted as one of the endpoint's attempts, since the endpoint neither answered nor refused; it goes out again after the restart. Requests already being handled are finished before the database closes, so a shutdown never leaves one half-applied.
One endpoint may hold at most 500 waiting events. Delivery is ordered, so a receiver that stops answering holds up everything behind it; without a ceiling its queue would grow for as long as the workspace stays busy. Past the ceiling events are counted as dropped rather than queued, and the count is shown beside the subscription. Once a delivery has used up its attempts, the rest of that endpoint's queue is given up on with it, so a dead receiver is not kept under load for days and an administrator repairing it does not face a backlog that drains one event every few hours. Retrying restores the whole queue in order. The dropped count clears once the endpoint is delivering again, or when an administrator retries.
Apps and integrations shows pending and terminally failed deliveries. An admin can retry failed work after repairing the endpoint. Terminal records are retained for seven days; deleting the subscription or app deletes its queue immediately. A deactivated bot receives no new events and its prior pending deliveries pause. Removing a bot from a channel discards queued events for that channel, so restoring membership does not disclose events from the revoked interval.
Replacing a leaked credential#
Apps and integrations offers a replacement for each of an app's three kinds of secret, without deleting the app or losing its commands, subscriptions and webhooks:
- New bot token replaces every token the app has. The old one stops working with that request, with no overlap, since a token is replaced because it has leaked. This is also how to get a token for an app whose original was never copied: the server stores tokens only as hashes and cannot show one again.
- Replace beside the signing secret takes effect on the next request the server signs, including event deliveries already waiting in the queue, which are signed when they are sent. The app rejects requests until it has the new secret.
- New URL on a webhook keeps its channel and replaces the secret in its URL. Anything posting to the old URL gets a 404.
Each replacement is logged with the app or webhook and the administrator who made it, never the credential itself.