Components · AI
Tool Call
BetaAdded v4.8.0
One tool call: its name and status, expandable to input and output.
import { ToolCall } from '@nexub/react';Playground
Props
status
search_invoicesDone
Input
{
"customer": "Acme",
"status": "unpaid"
}Output
{
"found": 3,
"total": "$4,120"
}<ToolCall input={{ customer: 'Acme', status: 'unpaid' }} output={{ found: 3, total: '$4,120' }} open status="done" name="search_invoices" />Examples
Tool call
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| namerequired | string | — | Tool name. |
| statusrequired | 'running' | 'done' | 'failed' | — | Shown as a badge. |
| input | unknown | — | Arguments, shown as JSON. |
| output | unknown | — | Result, as text or JSON. |
Accessibility
Screen reader
A native `<details>` disclosure: opens with Enter or Space.
On iOS & Android
Web only
Tool Call has no @nexub/react-native twin. On phones, follow the platform pattern instead, or compose it from the native components listed on the React Native page.