import { NoUserInfo, UserInfo, SwitchToOrganizationOptions } from './interfaces.js'; export interface RefreshAccessTokenActionResult { accessToken: string | undefined; error?: string; } /** * This action is only accessible to authenticated users, * there is no need to check the session here as the middleware will * be responsible for that. */ export declare const checkSessionAction: () => Promise; export declare const handleSignOutAction: ({ returnTo }?: { returnTo?: string; }) => Promise; export declare const getOrganizationAction: (organizationId: string) => Promise<{ id: string; name: string; } | null>; export declare const getAuthAction: (options?: { ensureSignedIn?: boolean; }) => Promise | { signInUrl: string; organizationId?: string | undefined; role?: string | undefined; roles?: string[] | undefined; permissions?: string[] | undefined; sessionId?: string | undefined; user: import("@workos-inc/node").User | null; entitlements?: string[] | undefined; featureFlags?: string[] | undefined; impersonator?: import("./interfaces.js").Impersonator | undefined; }>; export declare const refreshAuthAction: ({ ensureSignedIn, organizationId, }: { ensureSignedIn?: boolean; organizationId?: string; }) => Promise | { signInUrl: string; organizationId?: string | undefined; role?: string | undefined; roles?: string[] | undefined; permissions?: string[] | undefined; sessionId?: string | undefined; user: import("@workos-inc/node").User | null; entitlements?: string[] | undefined; featureFlags?: string[] | undefined; impersonator?: import("./interfaces.js").Impersonator | undefined; }>; export declare const switchToOrganizationAction: (organizationId: string, options?: SwitchToOrganizationOptions) => Promise>; /** * This action is used to get the access token from the auth object. * It is used to fetch the access token from the server. */ export declare function getAccessTokenAction(): Promise; /** * This action is used to refresh the access token from the auth object. * It is used to fetch the access token from the server. * * Errors are caught and returned as data rather than thrown, to prevent * Next.js from returning 500 responses for server action failures. */ export declare function refreshAccessTokenAction(): Promise;