Update a Hook. PATCH /api/openapi/v1/hook-policies/{policyId}, scope admin.v1.hooks.manage.
- Scope: admin.v1.hooks.manage
- Permission: Manage Hooks (hooks)
- Permission type: Manage
- Endpoint: PATCH/api/openapi/v1/hook-policies/{policyId}
Authentication and request headers
Call with an application API key. This endpoint checks only the scope above; read, manage and execute permissions do not imply one another.
| Name | Location | Type | Required | Description | Example |
|---|---|---|---|---|---|
| Authorization | header | string | Yes | Application API key, passed as a Bearer token. | Bearer qwk_*** |
| X-Request-Id | header | string | No | Optional request tracing identifier; generated by the server if omitted. | req-20260831-001 |
Request parameters
| Name | Location | Type | Required | Description | Example |
|---|---|---|---|---|---|
| policyId | path | string · uuid | Required | Policy group ID | "<uuid>" |
| config | body | any | Required | Rule configuration | "<string>" |
| description | body | string | Required | Policy description | "<string>" |
| enabled | body | boolean | null | Required | Enabled | false |
| event_name | body | string | Required | Trigger | "SessionStart" |
| name | body | string | Required | Policy name | "<string>" |
Request example
cURL
Responses
200 OK
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
| config | any | Yes | Rule configuration | "<string>" |
| created_at | string · date-time | Yes | Created at | "2026-08-27T10:00:00Z" |
| description | string | Yes | Policy description | "<string>" |
| enabled | boolean | Yes | Enabled | false |
| event_name | string | Yes | Trigger | "<string>" |
| id | string | Yes | Policy group ID | "<string>" |
| name | string | Yes | Policy name | "<string>" |
| updated_at | string · date-time | Yes | Updated at | "2026-08-27T10:00:00Z" |
default Flat business error
| Name | Type | Required | Description | Example |
|---|---|---|---|---|
| code | string | No | Stable business error code | "<string>" |
| detail | string | Yes | Human-readable error description | "<string>" |
| details | OpenapiErrorDetails | No | Error details | {"field":"<string>","reason":"<string>","suggestion":"<string>"} |
| details.field | string | No | Request field that failed validation | "<string>" |
| details.reason | string | No | Stable validation failure reason | "<string>" |
| details.suggestion | string | No | Suggested normalized value | "<string>" |
| error | string | Yes | Stable HTTP error type | "<string>" |