Skip to main content

Function: exportAgentConfigJSON()

exportAgentConfigJSON(agentInstance, metadata?, options?): string

Defined in: packages/agentos/src/api/agentExportCore.ts:187

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.

metadata?​

Optional human-readable metadata to attach.

author?​

string

description?​

string

name?​

string

tags?​

string[]

options?​

ExportAgentConfigOptions

Redaction options.

Returns​

string

JSON string with 2-space indentation.