Update a webhook configuration for a repository

Updates the webhook configuration for a repository. To update more information about the webhook, including the active state and events, use "Update a repository webhook."

Access tokens must have the write:repo_hook or repo scope, and GitHub Apps must have the repository_hooks:write permission.


string The token will be passed in the authorization header.




string The URL to which the payloads will be delivered.

string The media type used to serialize the payloads. Supported values include json and form. The default is form.

string If provided, the secret will be used as the key to generate the HMAC hex digest value for delivery signature headers.

string 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.


PATCH https://api.github.com/repos///hooks//config
authorization: bearer undefined
accept: application/vnd.github.v3+json
user-agent: octokit.rest
content-length: 0

Example Response

Status: 200
  "content_type": "json",
  "insecure_ssl": "0",
  "secret": "********",
  "url": "https://example.com/webhook"

See documentation on GitHub developer guides