---
title: "Update automation"
method: PATCH
path: "/v1/automations/{automationId}"
tags: ["Automations"]
---

# Update automation

`PATCH /v1/automations/{automationId}`

## Request

- Base URL: `https://api.1claw.co`
- URL: `https://api.1claw.co/v1/automations/{automationId}`
- Auth: HTTP bearer

## Path parameters

- `automationId` string, uuid, required

## Request body

- UpdateAutomationRequest
  - `name` string
  - `cron_expr` string, nullable
  - `timezone` string
  - `event_filter` object, nullable
  - `workflow_spec` union
    - object[]
    - object
  - `is_active` boolean
  - `approval_id` string, uuid: Control-plane approval authorising a widening change (adding a step that moves funds or reaches the network, raising or removing a `budget` cap). Required only when the org's consensus policy gates `automation.widen`.
  - `version_note` string: Note recorded on the new spec version.
  - `webhook_signature` object, nullable: Inbound signature scheme for a webhook-triggered automation. `stripe` (`Stripe-Signature: t=…,v1=…` over `<t>.<body>`), `github` (`X-Hub-Signature-256: sha256=…` over the body) or `hmac_sha256` (`<header>: <hex|base64>` over the body). The secret is stored encrypted and never returned; `null` removes the scheme. With a scheme set, an unsigned or mis-signed delivery starts nothing.
    - `scheme` 'stripe' | 'github' | 'hmac_sha256'
    - `secret` string
    - `header` string: Header carrying the signature (defaults per scheme).
    - `tolerance_secs` integer: Timestamp tolerance for schemes that carry one (stripe).

## Response `200`

Automation updated

- AutomationResponse
  - `id` string, uuid, required
  - `agent_id` string, uuid, required
  - `name` string, required
  - `trigger_type` 'cron' | 'event' | 'webhook' | 'manual', required
  - `cron_expr` string, nullable
  - `timezone` string, required
  - `event_filter` object, nullable
  - `workflow_spec` union, required
    - object[]
    - object
  - `is_active` boolean, required
  - `last_run_at` string, date-time, nullable
  - `next_run_at` string, date-time, nullable
  - `last_run_status` string, nullable: Status of the most recent run (enriched list field)
  - `total_runs` integer, nullable: Total runs in the last 30 days (enriched list field)
  - `success_rate` number, nullable: Success rate percentage (enriched list field)
  - `agent_name` string, nullable: Resolved agent display name (enriched list field)
  - `created_by_type` 'user' | 'agent': Whether the automation was created by a human or agent (chat-native create)
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `spec_version` integer: Current `automation_versions` version.
  - `webhook_signature_scheme` string, nullable: Inbound signature scheme name, never the secret.

## Other responses

- `400`: Invalid request
- `401`: Authentication required or invalid
- `404`: Resource not found

---

[API](https://skmtc.dev/1claw/apis/1claw-api.md) · [All operations](https://skmtc.dev/1claw/apis/1claw-api/llms.txt) · [OpenAPI document](https://skmtc.dev/1claw/apis/1claw-api/revisions/ae109b496830?raw)
