Skip to content

Credential

Defined in: core/src/auth/oauth.ts:33

The stored result of a sign-in.

accessToken: string;

Defined in: core/src/auth/oauth.ts:34


optional account?: string;

Defined in: core/src/auth/oauth.ts:42

For display: the account the token belongs to.


optional baseUrl?: string;

Defined in: core/src/auth/oauth.ts:48

Set when the vendor gives each account its own host (Copilot).


optional chatgptAccountId?: string;

Defined in: core/src/auth/oauth.ts:44

ChatGPT only: send it as the ChatGPT-Account-Id header.


expiresAt: number;

Defined in: core/src/auth/oauth.ts:40

Epoch ms, already moved earlier by REFRESH_SKEW_MS: refresh at or after this, it is not the server’s own expiry.


optional projectId?: string;

Defined in: core/src/auth/oauth.ts:46

Google Antigravity only: the Cloud Code Assist project id for the envelope.


refreshToken: string;

Defined in: core/src/auth/oauth.ts:37

What renews accessToken. Copilot keeps the GitHub token here and Meta its identity token. Empty for a key that never expires (OpenRouter).