Agent approvalsPro
One card for agents' tool calls: the call in plain words with code set in mono, the agent's reason, editable arguments; approve, deny or always allow for this agent or the whole workspace, which also clears every queued call the new rule covers. Rules and a decision log sit behind tabs.
oxyn add agent-approvalsvercel deploy --prod for northwind-webThe preview stays free for everyone. Pro opens the code of every Pro component, screen, agent-app template, block and kit, plus the Pro CLI.
Rendered from Rust at build time · goes live when visible
When to use
- One approval card for agents' tool calls.
- The waiting call reads like a permission prompt: tool mark, agent and model, the call in plain words with code in backticks set in mono (“Run vercel deploy --prod”), the agent's reason and its arguments as rows, some editable.
- Approve, Deny, or Always allow for this agent or the whole workspace; a new rule also clears every queued call it covers (logged as Auto-allowed).
- Rules (with Remove) and a decision log sit behind tabs.
When not to use
- An agent asks before it acts: use Approval Card instead.
- Several open requests in one card: use Approval pager instead.
- An agent's question in its own card above the composer: use Decision Card instead.
Installation
Agent approvals is part of Oxyn Pro; the preview is free. Pro items install with the oxyn CLI once your licence is signed in; until then Pro members copy the code from this page.
oxyn add agent-approvalsUsage
The preview is free. Pro opens the code of every Pro component, screen and template.
Examples
Queue
The waiting deploy with editable arguments.
vercel deploy --prod for northwind-webCode Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Rules
Always-allow rules with Remove.
Code Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
Fresh
No rules yet.
vercel deploy --prod for northwind-webCode Pro
The preview is free. Pro opens the code of every Pro component, screen and template.
API reference
AgentApprovals
| Prop | Type | Default | Description |
|---|---|---|---|
modelrequired | AgentModel | — | Model. |
title | String | "Approvals" | Heading. |
tab | String | "queue" | Tab shown first: `queue` · `rules` · `log`. |
on_decide | EventHandler<(bool, bool)> | — | Approve (`true`) or deny the top request; the flag says whether arguments were edited. |
on_always | EventHandler<RuleScope> | — | Always allow with a scope. |
on_arg | EventHandler<(String, String)> | — | An argument changed. |
on_remove_rule | EventHandler<usize> | — | A rule removed. |
Read from the Rust signature and doc comments.
Keyboard interactions
| Key | Action |
|---|---|
| Tab | Arguments, Deny, Approve, Always allow menu |
Accessibility
- Tabs are a real tablist; the always-allow menu is a menu of two menuitems.
- Edited arguments change the Approve label to “Approve edited” and are logged as edited.
From the spec
- Tabs use role=tab with aria-selected; the menu is role=menu with menuitems.
- Approve becomes “Approve edited” after an argument changes.
Motion & interaction
Timing
- Rows fade in (240 ms); reduced motion: none.
Responsive behaviour
- Max 520 px; arguments keep a 110 px key column.
Edge cases (spec)
- Max 520 px; 110 px argument key column.
Notes for AI
- Import
AgentApprovalsfromoxyn_dioxusand includeSTATUS_INDICATOR_CSSplus the token stylesheet once. - A GPUI version exists:
AgentApprovalsElinoxyn_gpui. - Props to set first:
model. - Keep its states and timings as they ship; restyle it through the CSS variables rather than by hand.