nexus-agents - v2.80.0
    Preparing search index...

    Function toolSuccessStructured

    MCP exports - MCP server implementation Split from index.ts for file size compliance (Issue #285) Updated Issue #538: Added missing tool registration exports

    • Creates a successful tool result with structured content for outputSchema validation.

      When a tool is registered with outputSchema, the SDK validates structuredContent against the schema. This helper returns both text (for display) and structured data.

      Parameters

      • data: Record<string, unknown>

        The structured result data (must match the tool's outputSchema)

      Returns ToolResult

      A ToolResult with both text content and structuredContent

      return toolSuccessStructured({ experts: [...], count: 10 });