Function: exportAgentConfig()
exportAgentConfig(
agentInstance,metadata?):AgentExportConfig
Defined in: packages/agentos/src/api/agentExport.ts:167
Exports an agent's configuration as a portable AgentExportConfig object.
Captures the full BaseAgentConfig including model, instructions,
personality, tools, guardrails, memory, RAG, voice, channels, and all
other configuration surfaces. For agency instances, the sub-agent roster,
strategy, and round limits are also included.
Parameters
agentInstance
Agent
The agent (or agency) instance to export.
metadata?
Optional human-readable metadata to attach to the export.
author?
string
Author identifier (person or system).
description?
string
Free-text description of what this agent does.
name?
string
Display name for the exported agent.
tags?
string[]
Searchable tags for categorization.
Returns
A portable config object that can be serialized to JSON or YAML.
Example
const config = exportAgentConfig(myAgent, {
name: 'Research Assistant',
author: 'team-alpha',
tags: ['research', 'summarization'],
});