Skip to main content
Create a webhook target. The response includes the signing secret once. Required scope: admin

Options

string
required
HTTPS URL that receives webhook deliveries.
string | undefined
Organization override.
string | undefined
Human-readable target name.
string[] | undefined
Event types to subscribe to. Defaults to ['push'] when omitted.
string[] | undefined
Restrict deliveries to specific repository IDs. Omit to receive events for all repositories in the organization.

Event names

Supported event names include repo.created, repo.updated, repo.deleted, bookmark.created, bookmark.deleted, bookmark.moved, bookmark.merged, change.created, change.evolved, push, sync.queued, sync.in_progress, sync.completed, and sync.failed.

Response

string
Webhook target ID.
string | null
Webhook target name, or null when unnamed.
string
Delivery URL.
string[]
Event names delivered to this target.
string[] | null
Repository allowlist, or null when the target receives events for all repositories.
string
Creation time.
string
Last update time.
string
Webhook signing secret. Store it immediately; it is shown only once.