Components
Kind: view (fills its container) · Session key: agentTasks · React: <FinBazeAgentTasks />
Create the session#
mutation {
createEmbedSession(input: {
companyId: "…"
user: { externalUserId: "…" }
components: { agentTasks: { enabled: true } }
}) { clientSecret }
}
Requirements#
The company must have these features effective: ai.agents. A hidden feature makes createEmbedSession fail with FEATURE_DISABLED.
Component features#
Switch these off per session with components.agentTasks.features.
| Feature | Default |
|---|---|
approve | on |
create | on |
manage | on |
Options#
Passed to instance.create("agent-tasks", options) or as props.
| Option | Type | |
|---|---|---|
taskId | string | Open this task instead of the list. |
Every component also takes appearance and navigation ("internal" or "external").
Events#
| Event | React prop |
|---|---|
ready | onReady |
navigate | onNavigate |
error | onError |
agent_task.approved | onAgentTaskApproved |
agent_task.rejected | onAgentTaskRejected |
agent_task.selected | onAgentTaskSelected |
Use it#
import { FinBazeAgentTasks } from "@finbaze/embed-react";
<FinBazeAgentTasks />
const component = instance.create("agent-tasks");
component.mount("#finbaze");