Create an organization webhook
Here’s how you can create a hook that posts payloads in JSON format:
Path Parameters
Body
application/json
Body
Must be passed as “web”.
Key/value pairs to provide settings for this webhook. These are defined below.
Show Child Parameters
Determines if notifications are sent when the webhook is triggered. Set to true
to send notifications.
Default:true
Response
application/json
Response
Response
Org Hook
Org Hook
Example:1
Example:https://api.github.com/orgs/octocat/hooks/1
Example:https://api.github.com/orgs/octocat/hooks/1/pings
Example:web
Example:["push","pull_request"]
Example:true
Show Child Parameters
Example:2011-09-06T20:39:23Z
Example:2011-09-06T17:26:27Z
Path Parameters
Body
Get an organization webhook
Returns a webhook configured in an organization. To get only the webhook config
properties, see “Get a webhook configuration for an organization.”
Path Parameters
Response
application/json
Response
Response
Org Hook
Org Hook
Example:1
Example:https://api.github.com/orgs/octocat/hooks/1
Example:https://api.github.com/orgs/octocat/hooks/1/pings
Example:web
Example:["push","pull_request"]
Example:true
Show Child Parameters
Example:2011-09-06T20:39:23Z
Example:2011-09-06T17:26:27Z
Path Parameters
Update an organization webhook
Updates a webhook configured in an organization. When you update a webhook, the secret
will be overwritten. If you previously had a secret
set, you must provide the same secret
or set a new secret
or the secret will be removed. If you are only updating individual webhook config
properties, use “Update a webhook configuration for an organization.”
Path Parameters
Body
application/json
Body
Key/value pairs to provide settings for this webhook. These are defined below.
Show Child Parameters
Determines if notifications are sent when the webhook is triggered. Set to true
to send notifications.
Default:true
Example:"web"
Response
application/json
Response
Response
Org Hook
Org Hook
Example:1
Example:https://api.github.com/orgs/octocat/hooks/1
Example:https://api.github.com/orgs/octocat/hooks/1/pings
Example:web
Example:["push","pull_request"]
Example:true
Show Child Parameters
Example:2011-09-06T20:39:23Z
Example:2011-09-06T17:26:27Z
Path Parameters
Body
Delete an organization webhook
Path Parameters
Response
Response
Response
Path Parameters
Get a webhook configuration for an organization
Returns the webhook configuration for an organization. To get more information about the webhook, including the active
state and events
, use “Get an organization webhook .”
Access tokens must have the admin:org_hook
scope, and GitHub Apps must have the organization_hooks:read
permission.
Path Parameters
Response
200 application/json
Response
Response
Webhook Configuration
Configuration object of the webhook
The URL to which the payloads will be delivered.
Example:https://example.com/webhook
The media type used to serialize the payloads. Supported values include json
and form
. The default is form
.
Example:"json"
If provided, the secret
will be used as the key
to generate the HMAC hex digest value for delivery signature headers.
Example:"********"
One Of
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.
Example:"0"