> ## Documentation Index
> Fetch the complete documentation index at: https://docs.support.onclarity.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Clone a campaign

> Creates a new `draft` campaign named "<name> (copy)" with the same settings and the same contacts (without their call results, and without any callback contacts created during calls). The copy has no start time. No request body.



## OpenAPI

````yaml /api-reference/voice-openapi.json post /v1/projects/{projectId}/campaigns/{id}/clone
openapi: 3.0.3
info:
  title: Clarity Voice API
  version: '1.0'
  description: Voice agents, outbound calls, conversations, campaigns, and evals.
servers:
  - url: https://voice-api.onclarity.com
security:
  - organizationApiKey: []
tags:
  - name: Projects
    description: >-
      The projects your organization owns. Every other resource lives in a
      project.
  - name: Agents
    description: Create, configure, version and publish voice agents.
  - name: Outbound calls
    description: Have a published agent phone a number now.
  - name: Conversations
    description: >-
      One record per call session, with its calls, recordings, transcripts and
      artifacts.
  - name: Calls
    description: The calls of a project, with their status, direction, timing and outcome.
  - name: Campaigns
    description: Outbound calling campaigns that phone a list of numbers on a schedule.
  - name: Eval suites
    description: >-
      Reusable sets of eval scenarios and test cases to measure an agent
      against.
  - name: Eval judges
    description: The LLM judges that score eval calls against your test cases.
  - name: Eval scenarios
    description: The simulated-caller scenarios of your eval suites.
  - name: Eval test cases
    description: The checks a judge applies to each eval call.
  - name: Eval submissions
    description: Run an eval suite against an agent and read the verdicts.
paths:
  /v1/projects/{projectId}/campaigns/{id}/clone:
    parameters:
      - $ref: '#/components/parameters/ProjectIdPath'
      - $ref: '#/components/parameters/CampaignId'
    post:
      tags:
        - Campaigns
      summary: Clone a campaign
      description: >-
        Creates a new `draft` campaign named "<name> (copy)" with the same
        settings and the same contacts (without their call results, and without
        any callback contacts created during calls). The copy has no start time.
        No request body.
      operationId: cloneCampaign
      responses:
        '201':
          description: The new campaign and its contacts
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CampaignDetailResponse'
              example:
                campaign:
                  id: 6e7f8a9b-0c1d-4e2f-9a3b-4c5d6e7f8a9b
                  project_id: 8d2e4b1a-1c3f-4e5a-9b7d-6f0a2c4e8b13
                  name: March renewals (copy)
                  agent_id: 5b7e9c1d-2a4f-4c6e-8d0b-1f3a5c7e9b24
                  from_number: '+14155550100'
                  start_time: null
                  callback: false
                  retries: 2
                  retry_delay_seconds: 3600
                  max_concurrency: 5
                  calling_window: null
                  status: draft
                  started_at: null
                  canceled_at: null
                  ended_at: null
                  created_at: '2026-03-05T08:00:00.000Z'
                  updated_at: '2026-03-05T08:00:00.000Z'
                items: []
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          description: No such campaign in this project.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  parameters:
    ProjectIdPath:
      name: projectId
      in: path
      required: true
      schema:
        type: string
      description: Project id
    CampaignId:
      name: id
      in: path
      required: true
      schema:
        type: string
      description: Campaign id
  schemas:
    CampaignDetailResponse:
      type: object
      required:
        - campaign
        - items
      properties:
        campaign:
          $ref: '#/components/schemas/Campaign'
        items:
          type: array
          items:
            $ref: '#/components/schemas/CampaignItem'
    Error:
      type: object
      required:
        - error
      additionalProperties: true
      properties:
        error:
          type: string
          description: Error message
        code:
          type: string
          description: >-
            A stable machine-readable reason, present on the refusals a client
            may branch on. Among them: `PUBLISH_CAPABILITY_REQUIRED` (403, the
            credential may not change what is live), `AGENT_NOT_PUBLISHED` (409,
            the agent has no published version yet),
            `AGENT_TYPE_NOT_DISPATCHABLE` (422, a Voice Assist agent named where
            an agent must place or take a call; the body carries `agent_type`
            and `agent_id`), `NOT_APPLICABLE_TO_AGENT_TYPE` (422, a voice-only
            setting written on a Voice Assist agent), `AGENT_TYPE_BOUNDARY`
            (409), `AGENT_TYPE_NOT_SUPPORTED` (400), `VOICE_ASSISTANT_REQUIRED`
            (403, the organization is not licensed for Voice Assist),
            `ORGANIZATION_UNAVAILABLE` (503) and `REGION_PROFILE_CONFLICT`
            (503).
    Campaign:
      type: object
      description: An outbound calling campaign.
      required:
        - id
        - project_id
        - name
        - callback
        - retries
        - retry_delay_seconds
        - max_concurrency
        - status
        - created_at
        - updated_at
      properties:
        id:
          type: string
        project_id:
          type: string
        name:
          type: string
        agent_id:
          type: string
          nullable: true
          description: Agent that places the calls, unless a contact names its own.
        from_number:
          type: string
          nullable: true
          description: Caller id the calls are placed from.
        start_time:
          type: string
          nullable: true
          description: When the campaign starts (or started) dialing. `null` for a draft.
        callback:
          type: boolean
          description: >-
            Default `callback` for new contacts (whether a callback is placed
            when the person asks to be called back).
        retries:
          type: integer
          description: How many more times an unanswered or failed contact is retried.
        retry_delay_seconds:
          type: integer
          description: Wait between attempts, in seconds.
        max_concurrency:
          type: integer
          description: Maximum simultaneous calls (5–20).
        calling_window:
          type: object
          nullable: true
          description: >-
            When the campaign may dial (same shape as `CampaignCallingWindow`).
            `null` means any time.
          properties:
            start:
              type: string
              description: 24-hour HH:MM
            end:
              type: string
              description: 24-hour HH:MM
            days:
              type: array
              items:
                type: integer
            timezone:
              type: string
        status:
          type: string
          enum:
            - draft
            - scheduled
            - running
            - canceled
            - ended
          description: >-
            `draft` (no start time), `scheduled` (will start at `start_time`),
            `running`, `canceled`, or `ended` (every contact finished).
        started_at:
          type: string
          nullable: true
        canceled_at:
          type: string
          nullable: true
        ended_at:
          type: string
          nullable: true
        created_at:
          type: string
        updated_at:
          type: string
        item_counts:
          type: object
          description: >-
            Number of contacts per contact status. Present in the list response
            only.
          additionalProperties:
            type: integer
    CampaignItem:
      type: object
      description: One contact on a campaign and the state of its call.
      required:
        - id
        - campaign_id
        - phone_number
        - channel
        - callback
        - custom_vars
        - status
        - attempt_count
        - callback_requested
        - created_at
        - updated_at
      properties:
        id:
          type: string
        campaign_id:
          type: string
        name:
          type: string
          nullable: true
        phone_number:
          type: string
        channel:
          type: string
          description: Always `voice`.
        country:
          type: string
          nullable: true
          description: >-
            ISO country code derived from the phone number; `null` when the
            number cannot be parsed.
        agent_id:
          type: string
          nullable: true
          description: Agent for this contact; `null` uses the campaign's agent.
        callback:
          type: boolean
        custom_vars:
          type: object
          description: Values the agent can use during the call, as string pairs.
          additionalProperties:
            type: string
        status:
          type: string
          enum:
            - draft
            - scheduled
            - ongoing
            - failed
            - ended
            - rescheduled
            - invalid
          description: >-
            `scheduled` (waiting to be dialed), `ongoing` (call in progress),
            `ended` (call completed), `failed` (all attempts failed),
            `rescheduled` (replaced by a callback contact), `invalid` (the
            number cannot be dialed).
        failed_reason:
          type: string
          nullable: true
        attempt_count:
          type: integer
        conversation_id:
          type: string
          nullable: true
          description: The conversation of the latest call to this contact.
        start_time:
          type: string
          nullable: true
        next_attempt_at:
          type: string
          nullable: true
          description: When the next retry is due.
        callback_requested:
          type: boolean
          description: The person asked to be called back during the call.
        callback_origin_item_id:
          type: string
          nullable: true
          description: For a callback contact, the contact whose call asked for it.
        callback_target_item_id:
          type: string
          nullable: true
          description: The callback contact created from this contact's call.
        created_at:
          type: string
        updated_at:
          type: string
        duration_sec:
          type: number
          nullable: true
          description: >-
            Total call duration in seconds. Returned by the get-campaign
            operation; `null` before a call.
        resolution:
          type: string
          nullable: true
          description: >-
            `resolved` or `unresolved` once the call has been judged; otherwise
            `null`. Returned by the get-campaign operation.
  responses:
    Unauthorized:
      description: No credential was sent, or the API key is invalid or revoked.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            error: Invalid or revoked token
    Forbidden:
      description: >-
        The credential carries no access to this project, or the operation needs
        administrative rights
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    organizationApiKey:
      type: http
      scheme: bearer
      description: >-
        Your organization API key (it starts with `anek_org_`). The same key
        works on the Voice API and the Support API. See
        [Authentication](/authentication).

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.