Does an organization owner's Settings → Webhooks page display OAuth-created organization webhooks? #213788
Replies: 2 comments
|
Short answer: no, it will not show up there. The Settings Webhooks page is not a complete inventory, because GitHub hides webhooks created by an OAuth app from users, even org owners.
The docs page is https://docs.github.com/en/rest/orgs/webhooks Let me know if it works. |
|
Short answer: no. The org Settings → Webhooks page shows only hooks that your own user/token context is allowed to see. The visibility rule in the REST docs applies to the UI as well: OAuth apps can't list, view or edit webhooks they didn't create, and users can't list, view or edit webhooks that were created by OAuth apps. That means there isn't one call that returns every hook on the org. You can still build a reasonably complete inventory: 1. Hooks visible to users (UI-created, or created with a PAT/GitHub App) gh api --paginate /orgs/ORG/hooks \
--jq '.[] | {id, name, active, events, url: .config.url, created_at, updated_at}'
2. Hooks created by each OAuth app These are visible only to that app's own token, so the same 3. Audit log, to find evidence of hooks you can't see Search the org audit log for
4. If you need certainty for hooks older than the retention window Open a ticket with GitHub Support and ask for a list of all org webhooks, including OAuth-created ones. Support can see what the owner UI and API can't. Separately, if any OAuth app shouldn't have access anymore, restricting it under OAuth app policy (or having members revoke it under Settings → Applications) removes its access to the org's resources. I'd confirm with Support whether its existing hooks keep firing after that, rather than assume either way. Docs: https://docs.github.com/en/rest/orgs/webhooks and https://docs.github.com/en/organizations/keeping-your-organization-secure/managing-security-settings-for-your-organization/reviewing-the-audit-log-for-your-organization |
Uh oh!
There was an error while loading. Please reload this page.
🏷️ Discussion Type
Question
💬 Feature/Topic Area
API
Body
I'm trying to confirm whether GitHub's organization Webhooks settings page provides a complete inventory of organization-level webhooks.
GitHub's REST API documentation states that OAuth applications cannot view hooks created by other applications and users cannot view hooks created by OAuth applications.
However, GitHub's web-interface documentation indicates that organization owners can manage organization webhooks through Settings → Webhooks.
I have three questions:
When an organization owner opens Settings → Webhooks, does the page show every organization webhook, including webhooks created through an OAuth application's API credentials?
If OAuth-created organization webhooks are not displayed, is there a supported way for an organization owner to obtain a complete inventory, including inactive or disabled hooks?
Can GitHub's organization audit log reliably establish whether OAuth-created organization webhooks exist, including hooks created before the available audit-log retention period?
I'm particularly interested in a response supported by GitHub documentation, a GitHub staff explanation, or a reproducible example.
I'm not looking to create or modify webhooks, only to understand whether the organization's settings page can be relied on as complete evidence of zero webhooks.
Thank you!
All reactions