Sample - GitHub REST API
PATCH/app/hook/config

Update a GitHub App webhook configuration

Updates the webhook configuration for a GitHub App. Supply the delivery url and optionally set the payload content_type, signing secret, or SSL verification behaviour with insecure_ssl.

  • RetriesRetries up to 2×, 500ms backoff, 30s timeout.

4 body fields

Webhook configuration settings for a GitHub App.

urlstringoptional
The URL to which the payloads will be delivered.
content_typestringoptional
The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.
secretstringoptional
If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/webhooks/event-payloads/#delivery-headers).
insecure_sslstringoptional
Controls SSL certificate verification for the delivery URL: use `0` to verify certificates or `1` to disable verification. Defaults to `0` when omitted.

1 status code
200Returns the updated webhook configuration, including the delivery URL, payload format, signing secret, and SSL verification setting.
urlstringoptional
The URL to which the payloads will be delivered.
content_typestringoptional
The media type used to serialize the payloads. Supported values include `json` and `form`. The default is `form`.
secretstringoptional
If provided, the `secret` will be used as the `key` to generate the HMAC hex digest value for [delivery signature headers](https://docs.github.com/webhooks/event-payloads/#delivery-headers).
insecure_sslstringoptional
Determines whether the SSL certificate of the host for `url` will be verified when delivering payloads. Supported values include `0` (verification is performed) and `1` (verification is not performed). The default is `0`. **We strongly recommend not setting this to `1` as you are subject to man-in-the-middle and other attacks.**

Error handling

url must be a valid URI. content_type supports json and form, while insecure_ssl supports 0 for certificate verification or 1 to disable verification; these fields use form and 0 by default when omitted.