Handles the creation and caching of credentials for GitHub integrations.
TODO: Possibly move this to a backend only package so that it's not used in the frontend by mistake
Returns GithubCredentials for a given URL.
The organization or repository URL
A promise of GithubCredentials.
Consecutive calls to this method with the same URL will return cached credentials.
The shortest lifetime for a token returned is 10 minutes.
const { token, headers } = await getCredentials({ url: 'https://github.com/backstage/foobar'})const { token, headers } = await getCredentials({ url: 'https://github.com/backstage'}) Copy
const { token, headers } = await getCredentials({ url: 'https://github.com/backstage/foobar'})const { token, headers } = await getCredentials({ url: 'https://github.com/backstage'})
Static
Handles the creation and caching of credentials for GitHub integrations.
Remarks
TODO: Possibly move this to a backend only package so that it's not used in the frontend by mistake