#Can you preload analysis data_collection items when creating an agent using an api? Or do I have to

1 messages · Page 1 of 1 (latest)

blissful tundraBOT
#
AI-generated Answer for .psytek

Short answer: You can automate it, but not in the Create Agent call itself.

What’s documented today:

  • Create Agent: the request schema documents conversation_config, platform_settings, name, tags, but does not document analysis/data_collection in the create payload. (elevenlabs.io)
  • Agents expose a data_collection block in their settings (identifiers with type, description, optional dynamic_variable/constant_value). It appears in the Agent schema returned by Get Agent. (elevenlabs.io)
  • You can set those via the Update Agent endpoint by PATCHing the agent with a data_collection object (same structure as shown above). (elevenlabs.io)

Practical ways to “preload”:

  • Create, then immediately PATCH the agent with your data_collection items. (elevenlabs.io)
  • Or keep a template agent that already has the desired data_collection and duplicate it for each new agent. (elevenlabs.io)

If you need exact JSON field names/types, use Get Agent to inspect a configured agent and mirror that structure in your Update request. (elevenlabs.io)

Sources:
Create agent | ElevenLabs Documentation
Get agent | ElevenLabs Documentation
Update agent | ElevenLabs Documentation
Update agent | ElevenLabs Documentation
Duplicate agent | ElevenLabs Documentation
Get agent | ElevenLabs Documentation

haughty basin
#

curl -X POST https://api.elevenlabs.io/v1/convai/agents/create
-H "xi-api-key: apikey"
-H "Content-Type: application/json"
-d '{
"conversation_config": {
"agent": {
"first_message": "hello",
"prompt": {
"prompt": "be cool"
}
},
"conversation": {}
},
"name": "zzzz",
"platform_settings": {
"data_collection": {
"1": {
"type": "string",
"description": "I still think we might be able to create it"
}
}
}
}'