@posthog/wizard
Version:
The PostHog wizard helps you to configure your project
36 lines (35 loc) • 1.14 kB
TypeScript
import { z } from 'zod';
import type { CloudRegion } from './types';
declare const OAuthTokenResponseSchema: z.ZodObject<{
access_token: z.ZodString;
expires_in: z.ZodNumber;
token_type: z.ZodString;
scope: z.ZodString;
refresh_token: z.ZodString;
scoped_teams: z.ZodOptional<z.ZodArray<z.ZodNumber, "many">>;
scoped_organizations: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
}, "strip", z.ZodTypeAny, {
access_token: string;
expires_in: number;
token_type: string;
scope: string;
refresh_token: string;
scoped_teams?: number[] | undefined;
scoped_organizations?: string[] | undefined;
}, {
access_token: string;
expires_in: number;
token_type: string;
scope: string;
refresh_token: string;
scoped_teams?: number[] | undefined;
scoped_organizations?: string[] | undefined;
}>;
export type OAuthTokenResponse = z.infer<typeof OAuthTokenResponseSchema>;
interface OAuthConfig {
scopes: string[];
cloudRegion: CloudRegion;
signup?: boolean;
}
export declare function performOAuthFlow(config: OAuthConfig): Promise<OAuthTokenResponse>;
export {};