Documentation
¶
Overview ¶
Package github provides GitHub App authentication, webhooks, and API client.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
App provides GitHub App authentication and webhook handling.
func NewAppFromTransport ¶
func NewAppFromTransport(tr *ghinstallation.AppsTransport, webhookSecret string) (*App, error)
NewAppFromTransport creates a new App using a pre-configured AppsTransport. This is useful for testing with custom base URLs.
func (*App) AppsTransport ¶ added in v0.26.0
func (a *App) AppsTransport() *ghinstallation.AppsTransport
AppsTransport returns the transport authenticated as the App itself, with the App JWT, for the App's own endpoints such as GET /app.
func (*App) InstallationTransport ¶ added in v0.26.0
func (a *App) InstallationTransport(installationID int64) *ghinstallation.Transport
InstallationTransport returns a transport authenticated as the given installation. It caches the installation token and mints a new one only when the cached one is due for refresh, so a process builds one and shares it.