Function exportAgentConfigJSON

  • Exports an agent's configuration as pretty-printed JSON. Class instances are always written as <<instance>> markers, since they cannot be serialized.

    Parameters

    • agentInstance: Agent

      The agent (or agency) instance to export.

    • Optional metadata: {
          name?: string;
          description?: string;
          author?: string;
          tags?: string[];
      }

      Optional human-readable metadata to attach.

      • Optional name?: string
      • Optional description?: string
      • Optional author?: string
      • Optional tags?: string[]
    • Optional options: ExportAgentConfigOptions

      Redaction options.

    Returns string

    JSON string with 2-space indentation.