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

# Update Workflow

> Partially update a workflow.

Partially update a workflow. Only provided fields are changed. Provider keys in `VERIFICATION` nodes must exist in `app.providers`.

## Request

<ParamField header="Authorization" type="string" required>
  `Bearer <API_KEY>` from Console > Developers > Workspace API Keys.
</ParamField>

<ParamField header="Content-Type" type="string">
  `application/json`
</ParamField>

### Path parameters

<ParamField path="client_id" type="string" required>
  Client identifier of the app.
</ParamField>

<ParamField path="workflow_id" type="string" required>
  Workflow identifier.
</ParamField>

### Request body

All fields are optional.

<ParamField body="name" type="string">
  Updated workflow name.
</ParamField>

<ParamField body="entryNodeId" type="string">
  Updated entry node ID.
</ParamField>

<ParamField body="nodes" type="object[]">
  Updated array of flow nodes.
</ParamField>

## Response

Returns the updated workflow object.

<RequestExample>
  ```bash theme={null}
  curl -X PATCH \
    -H "Authorization: Bearer sk_workspace_test_..." \
    -H "Content-Type: application/json" \
    -d '{"name": "KYC Premium v2"}' \
    "https://sandbox.api.hopae.com/connect/v1/apps/abc123/workflows/wf_abc123"
  ```
</RequestExample>

<ResponseExample>
  ```json theme={null}
  {
    "workflowId": "wf_abc123",
    "name": "KYC Premium v2",
    "entryNodeId": "nd_req",
    "nodes": [
      { "id": "nd_req", "type": "request", "next": "nd_verify" },
      { "id": "nd_verify", "type": "verification", "next": "nd_resp", "config": { "channel": "oidc", "claims": ["name", "birthdate"] } },
      { "id": "nd_resp", "type": "response" }
    ],
    "createdAt": "2025-01-15T10:00:00.000Z",
    "updatedAt": "2025-01-16T14:30:00.000Z"
  }
  ```
</ResponseExample>
