<ErrorMessage>

<ErrorMessage>

An error the model reads in its context on its next step. Input a tool refuses gets its message without this (Tools).

import { ErrorMessage } from "curb";

function ErrorMessage(props: { source?: string; children: ReactNode }): ReactNode;

Props

PropTypeWhat it does
sourcestringWhere the error came from: a tool’s name, or mcp:<server>
childrenReactNodeThe error text

Example

{lookupFailed && <ErrorMessage source="find_policy">The policy system is down. Offer to call back.</ErrorMessage>}

Version history

VersionChanges
v0.1.2<ErrorMessage> introduced