import { type OAuthCredentials, OAuthRefreshRejectedError } from "@bastani/pi-ai"; /** * Maps a rejected login reported by an extension's `refreshToken` in a common error shape onto * {@link OAuthRefreshRejectedError}, so it gets the same `/login` guidance as a built-in provider. Recognised on the * error or its `cause` chain: an OAuth error code that the built-in providers treat as a rejected login (such as * `invalid_grant`), in the error's `error` or `code` property or in an OAuth error response (flat or nested * `error.code`) in `body`, `data`, `response.data`, or `response.body`; or HTTP 401 in `status`, `statusCode`, * `response.status`, or `response.statusCode`. Errors that already are an `OAuthRefreshRejectedError` are left as * thrown. */ export declare function extensionRefreshRejection(error: unknown, credential: OAuthCredentials, providerName: string): OAuthRefreshRejectedError | undefined; //# sourceMappingURL=extension-oauth-refresh-rejection.d.ts.map