fix: Add App to HookType #89
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add missing
Appvalue toHookType.Looks like it's missing from the schema, but I'm 99.9% sure that this example from my GitHub App's tests that now fail with the latest update was adapted from the real webhook payload I received when I was developing it.
It would also make sense, because the documentation mentions the app-specific property
app_id.I just created a new app to test the theory using GHES 3.5.1, and this was the payload delivered to the newly-created app.
{ "zen": "Half measures are as bad as nothing at all.", "hook_id": 5692, "hook": { "type": "App", "id": 5692, "name": "web", "active": true, "events": [ "meta" ], "config": { "content_type": "json", "insecure_ssl": "0", "url": "https://GHESHOSTNAME/" }, "updated_at": "2022-07-07T07:51:54Z", "created_at": "2022-07-07T07:51:54Z", "app_id": 28, "deliveries_url": "https://GHESHOSTNAME/api/v3/app/hook/deliveries" } }