Skip to main content
POST
/
v1
/
duplicate-agent
/
{agent_id}
curl -X POST https://api.voicy.co/v1/duplicate-agent/550e8400-e29b-41d4-a716-446655440001 \
  -H "Authorization: Bearer voicy_sk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{"agent_name": "My Agent Copy"}'
{
  "agent_id": "660e8400-e29b-41d4-a716-446655440002",
  "agent_name": "My Agent Copy",
  "account": {
    "id": "550e8400-e29b-41d4-a716-446655440099",
    "name": "Acme Corp"
  },
  "voice_id": "openai:sage",
  "language": "en",
  "begin_message": "Hello! How can I help you today?",
  "agent_prompt": "You are a helpful customer support agent...",
  "begin_message_mode": "static",
  "prompt_text_direction": "ltr",
  "vars_provided": [
    {
      "name": "customer_name",
      "type": "string",
      "default_value": null,
      "description": "Customer's full name"
    }
  ],
  "vars_extracted": [
    {
      "name": "appointment_date",
      "type": "string",
      "description": "Preferred appointment date",
      "required": true
    }
  ],
  "version": 1,
  "deployed_at": null,
  "agent_type": "singlePrompt",
  "notification_emails": []
}
Create a complete copy of an existing agent, including all its configuration, variables, and prompts. The new agent will have a fresh ID and start at version 1.

Path Parameters

agent_id
string
required
The unique identifier of the agent to duplicate (UUID format).

Request Body

agent_name
string
Optional name for the duplicated agent. If not provided, defaults to “Copy of ”.

Response

Returns the newly created agent with all copied configuration.
agent_id
string
Unique identifier for the new agent.
agent_name
string
Display name for the agent.
voice_id
string
Voice ID (copied from original).
language
string
Language code (copied from original).
begin_message
string
Initial greeting message (copied from original).
agent_prompt
string
System prompt (copied from original).
begin_message_mode
string
How the begin message is handled (copied from original).
prompt_text_direction
string
Text direction for the prompt (copied from original).
vars_provided
array
Variable definitions copied from the original agent.
vars_extracted
array
Variable definitions copied from the original agent.
version
integer
Version number (always 1 for newly duplicated agents).
deployed_at
string
Always null - duplicated agents start as working versions.
curl -X POST https://api.voicy.co/v1/duplicate-agent/550e8400-e29b-41d4-a716-446655440001 \
  -H "Authorization: Bearer voicy_sk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{"agent_name": "My Agent Copy"}'
{
  "agent_id": "660e8400-e29b-41d4-a716-446655440002",
  "agent_name": "My Agent Copy",
  "account": {
    "id": "550e8400-e29b-41d4-a716-446655440099",
    "name": "Acme Corp"
  },
  "voice_id": "openai:sage",
  "language": "en",
  "begin_message": "Hello! How can I help you today?",
  "agent_prompt": "You are a helpful customer support agent...",
  "begin_message_mode": "static",
  "prompt_text_direction": "ltr",
  "vars_provided": [
    {
      "name": "customer_name",
      "type": "string",
      "default_value": null,
      "description": "Customer's full name"
    }
  ],
  "vars_extracted": [
    {
      "name": "appointment_date",
      "type": "string",
      "description": "Preferred appointment date",
      "required": true
    }
  ],
  "version": 1,
  "deployed_at": null,
  "agent_type": "singlePrompt",
  "notification_emails": []
}