---
title: "Add your own paused copy of a shared Automation"
method: POST
path: "/v1/shared-automations/{id}/copy"
tags: ["Automations"]
---

# Add your own paused copy of a shared Automation

`POST /v1/shared-automations/{id}/copy`

## Request

- Base URL: `https://api.openworklabs.com`
- URL: `https://api.openworklabs.com/v1/shared-automations/{id}/copy`
- Auth: one of:
  - API key in header `x-api-key`
  - HTTP bearer

Copies the current shared definition into a new Automation you own, paused for review. Optionally choose a name and agent model. Uses your own connections and validates your model and Workflow access. Never copies the source workspace, runs, or results. Review and activate your copy when ready.

## Path parameters

- `id` string, required

## Request body

- CopySharedAutomation
  - `name` string
  - `model` object
    - `providerId` string, required
    - `modelId` string, required
    - `variant` string, nullable

## Response `201`

Paused copy created.

- AutomationDetail
  - `automation` Automation, required
    - `id` string, required
    - `organizationId` string, required
    - `ownerMemberId` string, required
    - `name` string, required
    - `state` 'active' | 'inactive' | 'needs_attention' | 'archived', required
    - `currentRevisionId` string, required
    - `nextDueAt` integer, nullable, required
    - `latestRunAt` integer, nullable, required
    - `latestSuccessfulRunId` string, nullable
    - `latestSuccessfulResult` unknown
    - `needsAttentionReason` AutomationNeedsAttentionReason, nullable, required
      - `code` 'owner_membership_lost' | 'model_access_lost' | 'provider_unavailable' | 'connect_access_unavailable' | 'openwork_web_access_required' | 'execution_runtime_unavailable', required
      - `message` string, required
      - `occurredAt` integer, required
    - `agentId` string, nullable
    - `createdAt` integer, required
    - `updatedAt` integer, required
    - `archivedAt` integer, nullable, required
  - `revision` AutomationRevision, required
    - `id` string, required
    - `automationId` string, required
    - `version` integer, required
    - `instructions` string, required
    - `schedule` union, required
      - object
        - `kind` 'once', required
        - `timezone` string, required
        - `at` integer, required
      - object
        - `kind` 'daily', required
        - `timezone` string, required
        - `hour` integer, required
        - `minute` integer, required
      - object
        - `kind` 'weekly', required
        - `timezone` string, required
        - `daysOfWeek` integer[], required
        - `hour` integer, required
        - `minute` integer, required
      - object: Every everyHours hours on the hour, counted from startHour on each listed day (0 = Sunday) and stopping before endHour, in timezone. Needs the organization's every-few-hours schedules.
        - `kind` 'interval', required
        - `timezone` string, required
        - `everyHours` integer, required
        - `daysOfWeek` integer[]
        - `startHour` integer
        - `endHour` integer
      - object: Runs offsetMinutes (negative is before) from the start or end of each meeting on the owner's primary Google Calendar: timed meetings they accepted or organize, with someone else invited. Cloud Automations only; needs Google Calendar connected and the organization's before-and-after-meeting Automations.
        - `kind` 'calendar', required
        - `timezone` string, required
        - `edge` 'start' | 'end', required
        - `offsetMinutes` integer, required
        - `rule` object
          - `withExternalAttendees` boolean
          - `titleIncludes` string
      - object
        - `kind` 'event', required
    - `model` object, required
      - `providerId` string, required
      - `modelId` string, required
      - `variant` string, nullable
    - `action` union
      - object
        - `kind` 'agent', required
        - `instructions` string, required
        - `model` object, required
          - `providerId` string, required
          - `modelId` string, required
          - `variant` string, nullable
      - object
        - `kind` 'saved_script', required
        - `script` object, required
          - `pluginId` string, required
          - `configObjectId` string, required
          - `configObjectVersionId` string, required
        - `input` unknown
    - `executionTarget` 'desktop' | 'cloud'
    - `workspaceId` string, nullable
    - `agentRevisionId` string, nullable
    - `maximumRuntimeMs` integer, required
    - `digest` string, required
    - `createdAt` integer, required
  - `latestRun` AutomationRun, nullable, required
    - `id` string, required
    - `automationId` string, required
    - `revisionId` string, required
    - `trigger` 'scheduled' | 'recovery' | 'manual', required
    - `scheduledFor` integer, nullable, required
    - `idempotencyKey` string, required
    - `status` 'queued' | 'claimed' | 'running' | 'succeeded' | 'failed' | 'cancelled' | 'skipped', required
    - `leaseOwner` string, nullable, required
    - `leaseExpiresAt` integer, nullable, required
    - `heartbeatAt` integer, nullable, required
    - `attemptCount` integer, required
    - `executionTarget` 'desktop' | 'cloud', required
    - `executionThread` AutomationExecutionThread, nullable, required
      - `id` string, required
      - `threadKind` 'automation', required
      - `executionLocation` 'desktop' | 'cloud', required
      - `automationId` string, required
      - `automationRunId` string, required
      - `engineKind` string, required
      - `nativeThreadId` string, nullable
      - `workspaceId` string, nullable
    - `providerId` string, required
    - `modelId` string, required
    - `modelVariant` string, nullable
    - `startedAt` integer, nullable, required
    - `finishedAt` integer, nullable, required
    - `error` AutomationError, nullable, required
      - `code` 'owner_membership_lost' | 'model_access_lost' | 'provider_unavailable' | 'connect_access_unavailable' | 'openwork_web_access_required' | 'execution_runtime_unavailable' | 'connection_action_required' | 'execution_failed' | 'execution_timed_out' | 'runner_unavailable' | 'cancelled' | 'lease_lost' | 'internal_error', required
      - `message` string, required
      - `retryable` boolean, required
    - `resultSummary` string, nullable, required
    - `codemodeReceiptId` string, nullable
    - `validatedResult` unknown
    - `triggerContext` AutomationRunTriggerContext, nullable
      - `kind` 'calendar_meeting', required
      - `eventId` string, required
      - `title` string, nullable, required
      - `start` integer, required
      - `end` integer, required
      - `attendeeDomains` string[], required
      - `externalAttendees` integer, required
      - `link` string, nullable, required
    - `usage` AutomationUsage, required
      - `inputTokens` integer, nullable, required
      - `outputTokens` integer, nullable, required
      - `costMicros` integer, nullable, required
    - `createdAt` integer, required
    - `updatedAt` integer, required

## Other responses

- `400`: Invalid definition.
- `403`: Placement or Workflow access unavailable.
- `404`: Not shared with you or sharing disabled.
- `409`: Runtime or model access unavailable.

## Changes

- **2026-12-02** `b20ab6931f6a`: 1 breaking
  - added `subschema #6` to the `revision/schedule` response property `oneOf` list for the response status `201`
- **2026-11-26** `bc0092687a7b`: 2 info
  - added the optional property `automation/agentId` to the response with the `201` status
  - added the optional property `revision/agentRevisionId` to the response with the `201` status
- **2026-11-18** `a38fd1c0264f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/openworklabs/apis/den-api/changes/v1/shared-automations/:id/copy/post.md)

---

[API](https://skmtc.dev/openworklabs/apis/den-api.md) - [All operations](https://skmtc.dev/openworklabs/apis/den-api/llms.txt) - [OpenAPI document](https://skmtc.dev/openworklabs/apis/den-api/revisions/84fb0f99fb95?raw)
