CHATBOTS
Auto-Expiry Sweep for Time-Boxed Warehouse Grants
A scheduled job that finds Snowflake grants whose access window has expired in the ledger, revokes them automatically.
How it runs
The automated pipeline, trigger to output.
- TriggerScheduled sweep fires (hourly)
- ActionQuery ledger for grants past expires_atPostgres
- LogicExit if no grants are due for revocation
- ActionExecute REVOKE for each expired grant in SnowflakeSnowflake
- ActionMark ledger rows as revoked with timestampPostgres
- OutputPost revocation digest to governance Slack channelSlack
What it does
Enforces the expiry side of time-boxed access. Every grant in the audit ledger carries an `expires_at`; this job runs on a schedule, finds the ones that have lapsed, executes the matching `REVOKE` in Snowflake, marks the ledger row as revoked, and reports the sweep. No human has to remember to clean up temporary access.
When to use it
Use it alongside any self-serve grant flow where access is meant to be temporary. Without automatic revocation, "two-week" grants quietly become permanent and access reviews balloon. This keeps the live grant set matching the approved-and-still-valid set.
How it works
- 1A schedule fires the sweep (e.g. hourly).
- 2The job queries the Postgres ledger for active grants where `expires_at` is in the past.
- 3If none are due, it exits quietly.
- 4For each expired grant it runs the corresponding `REVOKE ... FROM ROLE` in Snowflake.
- 5It updates each ledger row to `revoked` with a timestamp and reason.
- 6It posts a digest of revoked grants (user, object, original approver) to the governance Slack channel.
Set it up
What you configure once, before turning it on.
- 1Connect PostgresAny Postgres URL — query, write, migrate.
- 2Connect SnowflakeWarehouses, queries, shares.
- 3Connect SlackChannels, DMs, threads, mentions.
- 4Set each agent's modelWe leave models unset so you pick the tier — fast + cheap, or top-quality.
- 5Tune it to your dataEdit the prompts, filters, and field mappings so it matches how your team works.
- 6Test, then turn it onRun once against a sample, confirm the output, then enable the trigger.
More Chatbots workflows
Discord FAQ Free-Text Answer Grader
When a member submits a free-text answer in their onboarding thread, an agent grades it against the canonical FAQ knowledge base, replies with targeted feedback.
Discord intro-gated role granting concierge
Watches your #introductions channel, uses AI to confirm a new member's intro is genuine and complete, then auto-assigns the verified Member role and welcomes them.
Intercom-to-HubSpot Sync When an Activation Call Is Booked
When a Zoom activation call gets booked from an Intercom chat, enriches the lead in HubSpot, logs the meeting, and posts an AI-written prep brief to the assigned rep in Slack.
Discord FAQ-Gated Role Concierge
Greets each new Discord member in a private onboarding thread, walks them through required FAQ steps one at a time.
Discord verify-button onboarding via web form webhook
Receives a completed external verification form by webhook, matches it to the Discord account, grants the verified role, and confirms back to the member in Discord.
Discord Onboarding Completion to CRM Sync
The moment a member finishes Discord onboarding, captures their submitted profile answers, creates or updates a contact in HubSpot.
Run it inside a business
This workflow drops into a full company template. Import the org, and this is one of the playbooks its agents run.

Run this workflow in your colony.
14-day trial. No DevOps. No Sales call. Provisioned in under a minute.
