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

# webhook_targets.update()

> Update a webhook delivery target.

Update fields on a webhook target. Omitted fields are left unchanged.

**Required scope: `admin`**

```python theme={null}
target = await mesa.webhook_targets.update(
    webhook_target_id="wh_123",
    url="https://example.com/mesa/new-webhook",
    events=["push"],
)
```

## Options

<ParamField path="webhook_target_id" type="str" required>
  Webhook target ID.
</ParamField>

<ParamField path="org" type="str | None">
  Organization override.
</ParamField>

<ParamField path="url" type="str | None">
  New delivery URL.
</ParamField>

<ParamField path="name" type="str | None">
  New target name.
</ParamField>

<ParamField path="events" type="list[str] | None">
  Replacement event list.
</ParamField>

<ParamField path="repo_ids" type="list[str] | None">
  Replacement repository ID filter. The high-level method treats `None` as omitted; use `clear_repo_filter()` to send an explicit `null`.
</ParamField>

## Response

<ResponseField name="id" type="str">
  Webhook target ID.
</ResponseField>

<ResponseField name="name" type="str | None">
  Webhook target name, or null when unnamed.
</ResponseField>

<ResponseField name="url" type="str">
  Delivery URL.
</ResponseField>

<ResponseField name="events" type="list[str]">
  Event names delivered to this target.
</ResponseField>

<ResponseField name="repo_ids" type="list[str] | None">
  Repository allowlist, or null when the target receives events for all repositories.
</ResponseField>

<ResponseField name="created_at" type="datetime">
  Creation time.
</ResponseField>

<ResponseField name="updated_at" type="datetime">
  Last update time.
</ResponseField>
