/** * The refreshed GitHub token, in the shape GitHub's token endpoint returns it. */ export interface RefreshedGitHubToken { access_token: string; refresh_token?: string; expires_in?: number; } /** * Refresh the stored GitHub token using its saved refresh token, rewrite * `~/.hublaunch/github-token` (mode 0o600) with the new values, and * best-effort re-authenticate the `gh` CLI with the fresh token. * * This is the single implementation shared by `hula login` (token reuse) and * `checkGhAuth` (proactive/expired refresh) so both behave identically. The * caller supplies the loaded config (for the GitHub App client ID) to avoid a * redundant `loadConfig()` call. * * `../commands/login.js` is imported dynamically to avoid a static module cycle * (login.ts imports this util), matching the pattern in `github-cli.ts` and * `github-token.ts`. * * @returns the refreshed token object, or `null` when there is no refresh token * or the refresh request failed. Never throws. */ export declare function refreshStoredGitHubToken(config: any): Promise; //# sourceMappingURL=github-token-refresh.d.ts.map