ACP v2 (Preview) TypeScript SDK — EXPERIMENTAL - v2.12.1
    Preparing search index...

    Type Alias ToolCallUpdateExperimental

    Represents an upsert for a tool call that the language model has requested.

    Tool calls are actions that the Agent executes on behalf of the language model, such as reading files, executing code, or fetching data from external sources.

    Only toolCallId is required. Other fields have patch semantics: omitted fields leave the existing tool call value unchanged, null clears or unsets the value, and concrete values replace the previous value. For collection fields, concrete arrays replace the previous collection, and both null and [] clear the collection. A concrete _meta object instead patches the stored metadata by top-level key. When a Client receives a tool call ID it has not seen before, omitted fields start at their protocol defaults.

    See protocol docs: Tool Calls

    type ToolCallUpdate = {
        toolCallId: ToolCallId;
        name?: string | null;
        title?: string | null;
        kind?: ToolKind | null;
        status?: ToolCallStatus | null;
        content?: ToolCallContent[] | null;
        locations?: ToolCallLocation[] | null;
        rawInput?: unknown;
        rawOutput?: unknown;
        capabilities?: ToolCallCapabilities | null;
        _meta?: { [key: string]: unknown } | null;
    }
    Index
    toolCallId: ToolCallId

    Unique identifier for this tool call within the session.

    name?: string | null

    Programmatic name of the tool being invoked.

    This field is optional and has patch semantics. Omission means no change, null clears the name, and a string replaces it. For a tool call ID the Client has not seen before, omission or null means that no tool name is available.

    title?: string | null

    Human-readable plain-text title describing what the tool is doing.

    Omission leaves the title unchanged, null unsets it, and a string replaces it. A new tool call starts without a title.

    kind?: ToolKind | null

    The category of tool being invoked. Helps Clients choose appropriate icons and UI treatment.

    Omission leaves the kind unchanged, null resets it to other, and a value replaces it. A new tool call starts as other.

    status?: ToolCallStatus | null

    Current execution status of the tool call.

    Omission leaves the status unchanged, null resets it to pending, and a value replaces it. A new tool call starts as pending. Agents do not move a tool call back to pending once it has another status.

    content?: ToolCallContent[] | null

    Content produced by the tool call.

    locations?: ToolCallLocation[] | null

    File locations affected by this tool call. Enables "follow-along" features in Clients.

    rawInput?: unknown

    Raw input parameters sent to the tool.

    rawOutput?: unknown

    Raw output returned by the tool.

    capabilities?: ToolCallCapabilities | null

    Client-initiated controls this tool call currently supports, such as cancellation.

    Omission leaves the capabilities unchanged, null clears them, and an object replaces the whole previous value. A new tool call starts with none.

    _meta?: { [key: string]: unknown } | null

    The _meta property is reserved by ACP to allow Clients and Agents to attach additional metadata to their interactions. Omitted leaves the stored metadata unchanged. null clears it. An object patches the stored metadata by top-level key: keys it omits are unchanged, a key set to null is removed, and any other value replaces that key's stored value without merging nested objects. Beyond this patch rule, implementations MUST NOT assign meaning to keys they do not recognize.

    See protocol docs: Metadata Patches