What is the difference between installation.created and installation_repositories.added #24379
-
I am just starting out on developing my first GitHub app and I am not sure if I understand the use of the installation resource yet. My main concern now is that I am unable to understand the difference between the |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
Hey, hey @sayakmukhopadhyay! Been a while on this post, but I’m going back through the API category for unanswered topics and didn’t want to let this slip through. It’s entirely possible you’ve already found your answer, but if anyone else comes looking, our docs speak to the differences. For https://docs.github.com/en/developers/webhooks-and-events/webhook-events-and-payloads#installation
…and note:
Then, for
…and note:
I’ve merely quoted our docs here, so please do let us know if there’s any remaining confusion! It’s possible our docs could do with some pruning and feedback is certainly welcome. |
Beta Was this translation helpful? Give feedback.
-
Thanks for jumping in. My main concern was knowing when exactly are these events triggered. Things like if one of the events can be triggered without the other Some examples would go a long way in understanding. Use cases and such. |
Beta Was this translation helpful? Give feedback.
-
Hey @sayakmukhopadhyay apologies; yes, you did ask about the So For I really hope that helps clear up what the docs mean, but let us know if you have any more questions! |
Beta Was this translation helpful? Give feedback.
Hey @sayakmukhopadhyay apologies; yes, you did ask about the
when
, not just the differences between them!So
installation
is related to events when your app is installed on an Org, or Repository. Since an install can happen at the Org level for all, or specific repositories, you might not get a subsequent webhook triggered on a repository within an Org where all repositories are selected.For
installation_repositories
, the webhook is there for those specific repositories that install your app. So say on the initial installation to an Org where they apply it toall
repositories, you would only see the install event for the Org, but then you would see subsequentinstallation_repositories
ev…