What a person does once they have seen something built for agents: hand it to their coding agent, as one line to paste, with Copy beside it. The line is in the page's own type, never a terminal's, and a web address in it can break after each "/". Copy is CopyButton, which says it copied on itself, where the person is looking. In a narrow column Copy goes under the line, so the line has the column's whole width. It takes its container's width.
On this site
This site's own pages use AgentHandoff too. Open one with X-ray pointing it out: The home page
Install
Add AgentHandoff from Ouro UI to this app. Read https:// ui.ouroboros.bot/ docs/ agent-handoff.md first and follow it.Or by hand. Once per app, with Tailwind CSS v4 and an @/* path alias (Ouro HX is built on Base UI, so --base base; skip -t in an existing app):
npx shadcn@latest init --base base --preset nova --yes --no-monoreponpx shadcn@latest add ourostack/ouro-ui/ouro-base#v1.3.344Then the component. From v0.8.0 it installs only the helpers it imports and never touches your stylesheet (Installing):
npx shadcn@latest add ourostack/ouro-ui/agent-handoff#v1.3.344Or, with the @ouro namespace set up:
npx shadcn@latest add @ouro/ouro-base @ouro/agent-handoffIts tests, stories and Playwright spec are optional. They need Vitest 4.1.11 or later, and from v0.8.0 never change a version your app has (Testing):
npx shadcn@latest add ourostack/ouro-ui/agent-handoff#v1.3.344 ourostack/ouro-ui/agent-handoff-tests#v1.3.344import { AgentHandoff } from "@/components/ouro/agent-handoff/agent-handoff";Paths use shadcn's default @/ alias; the CLI rewrites them to yours.
Example
<AgentHandoff
label="Hand it to your agent"
prompt="Build this app's interface with Ouro UI. Read https://ui.ouroboros.bot/llms.txt first and follow it."
caption="Paste it into your coding agent's chat."
/>Use instead when
- Use
CopyButtoninstead for a value that isn't an instruction to an agent, andCodeBlockinstead for a command to run in a terminal.
Props
Type: AgentHandoffProps.
aside- Type:
ReactNode - At the end of the label's row, such as a Badge with the release the line brings in.
caption- Type:
ReactNode - Under the line, such as "Paste it into your coding agent's chat."
className- Type:
string - Layout only: margins, width (
mt-8,max-w-xl). Appearance classes warn in development. copiedLabel- Type:
string - Default:
"Copied" - What the Copy button says once the line is on the clipboard.
copyLabel- Type:
string - Default:
"Copy" - The Copy button's label.
failedMessage- Type:
string - Default:
"The browser blocked copying. Select the line and copy it yourself." - What screen readers hear, and the Copy button's tooltip says, when the browser refused to copy.
label(required)- Type:
ReactNode - What the person does with the line, above it, which also names the group: "Hand it to your agent".
prompt(required)- Type:
string - The one line to paste into a coding agent's chat, in the page's own type. A web address in it can break after each "/", between its parts, but not inside "//".
ref- Type:
Ref<HTMLDivElement> - Reaches the rendered element.
Native attributes
Also accepts the attributes in React's HTMLAttributes (id, aria-*, event handlers), passed to the rendered element, except those named on this page.
Don't use
These are not props. Passing one fails the type check with the fix in the error, and in development a console message names the fix.
command: Not a prop. AgentHandoff hands an agent a line to paste,prompt; for a command to run in a terminal, use CodeBlock.description: Not a prop. The words under the line arecaption:<AgentHandoff caption="Paste it into your coding agent's chat." />.hint: Not a prop. The words under the line arecaption:<AgentHandoff caption="Paste it into your coding agent's chat." />.text: Not a prop. The line to paste isprompt:<AgentHandoff prompt="Read https://example.com/llms.txt" />.title: Not a prop. The words above the line arelabel:<AgentHandoff label="Hand it to your agent" />.value: Not a prop. The line to paste isprompt:<AgentHandoff prompt="Read https://example.com/llms.txt" />.
className is for layout only
Pass margins, width and grid placement (mt-4, w-full, col-span-2). Your classes always win over Ouro UI's: AgentHandoff merges className last with cn (tailwind-merge), so a class that conflicts with its own replaces it.layout-classes
Appearance comes from props, not classes. In development, a class that sets appearance logs one warning per component instance, naming the prop to use instead. A class sets appearance when, after its variants (hover:, sm:) and any ! are removed, it starts with bg-, text-, border-, rounded-, shadow-, font-, ring-, from-, via-, to-, fill- or stroke-, or is border, rounded, shadow or ring, or has a dark: variant. Text wrapping, overflow and table layout classes (text-wrap, text-ellipsis, border-collapse) are layout and do not warn.
Alignment classes (text-center) warn too: set alignment on a parent element.
Claim sources
- layout-classes: test:registry/ouro/components/ouro/agent-handoff/agent-handoff.test.tsx::AgentHandoff > forwards a ref, passes attributes through, and lets the app's layout classes win
verify:testExists(registry/ouro/components/ouro/agent-handoff/agent-handoff.test.tsx::AgentHandoff > forwards a ref, passes attributes through, and lets the app's layout classes win)

