# Update workflow config

> Wire credentials, const values, and trigger schedules. Send only the fields you are changing.

Source: https://docs.generalinput.com/api/workflows/update-config



<Endpoint method="PATCH" path="/v1/workflows/:id/config" />

<Access scope="workflows:manage" />

A partial patch. Omitted keys are untouched. Find credential ids in the [vault](/api/vault/list-credentials) and trigger ids in the workflow's `workflow.json`.

## Body [#body]

| Field         | Type   | Notes                                                                                       |
| ------------- | ------ | ------------------------------------------------------------------------------------------- |
| `credentials` | object | Service slug to credential id, or `null` to clear the slot.                                 |
| `variables`   | object | Const key to value. Values keep their JSON type.                                            |
| `triggers`    | object | Trigger id to a patch of `schedule`, `timezone`, `selectedCredentialId`, and `inputValues`. |

```json
{
  "credentials": { "slack": "cred_01HX…", "gmail": null },
  "variables": { "days": 7 },
  "triggers": {
    "daily": { "schedule": "0 9 * * 1-5", "timezone": "America/New_York" }
  }
}
```

## Response [#response]

```json
{
  "ok": true,
  "applied": ["credentials.slack", "variables.days", "triggers.daily.schedule"]
}
```

A rejected patch answers `200` with `{ "ok": false, "errors": [...] }`, each error naming the binding that failed (an unknown slot, a credential of the wrong service, an invalid cron expression).
