import { SnakeCaseKeys } from './../../utils/util.types'; export interface UserData { id: number; type: string; email: string; roles: any[]; permissions: any[]; address: { house_name: string | null; house_number: number | string | null; street_address: string | null; address_2: string | null; town: string | null; county: string | null; postcode: string | null; }; first_name: string | null; last_name: string | null; tel_home: string | null; tel_mobile: string | null; avatar_url: string | null; employee_subdomain: string | null; branch_id: number | null; agency_id: number | null; portal_id: number | null; domain: string | null; terms_agreed_at: string; terms_version_agreed: number; is_sales_applicant_at: string | null; is_lettings_applicant_at: string | null; is_vendor_at: string | null; is_landlord_at: string | null; do_not_contact: boolean; saved_properties: { lettings: any[]; sales: any[]; }; saved_searches: any[]; marketing_preferences: MarketingPreferences; } /** camelCase params used by Lead model and user helper register/create */ export interface UserCreateParams { email: string; password: string; passwordConfirmation: string; firstName: string; lastName: string; telHome?: string; streetAddress?: string; address2?: string; town?: string; county?: string; postcode?: string; isSalesApplicant?: boolean; isLettingsApplicant?: boolean; isVendor?: boolean; isLandlord?: boolean; optInMarketing?: boolean; optInTerms?: boolean; optInUrl?: string; } export interface UserUpdateParams { title?: string; firstName?: string; lastName?: string; email?: string; telHome?: string; telMobile?: string; houseName?: string; houseNumber?: string; streetAddress?: string; town?: string; county?: string; postcode?: string; address2?: string; isSalesApplicant?: boolean; isLettingsApplicant?: boolean; isVendor?: boolean; isLandlord?: boolean; } export type UserUpdateSnakeParams = { user: SnakeCaseKeys; }; export interface UserUpdateResponse { user: any; error?: string; } export interface AuthResponse { access_token?: string; token_type?: string; expires_in?: number; refresh_token?: string; scope?: string; created_at?: number; error?: string; error_description?: string; } export interface SessionCookie { name: string; domain: string; value_b64: string; expires: string; secure: boolean; httponly: boolean; http_only: boolean; } export interface SessionsResponse { cookie?: SessionCookie; user?: UserData; oauth?: { access_token: string; refresh_token: string; token_type: string; expires_in: number; expires_at: string; }; error?: string; error_description?: string; } export interface RegisterResponse { user: UserData; } export interface MarketingPreferences { opt_in_marketing?: string; opt_in_marketing_statement?: string | null; opt_in_marketing_url?: string | null; opt_in_terms?: string; opt_in_terms_at?: string | null; opt_in_marketing_at?: string | null; double_opt_in_at?: string; double_opt_in_marketing_statement?: string | null; opt_out_marketing_at?: string | null; custom_preferences?: unknown; } export type MarketingPreferencesResponse = Omit & { user_id?: number; id?: number; created_at?: string; updated_at?: string; error?: { status: number; }; }; export type PasswordResetUpdateParams = { password: string; passwordConfirmation: string; token: string; }; export type PasswordResetUpdateResponse = { message: string; user: UserData; error?: { status: number; }; }; export type PasswordResetCreateResponse = { password_reset: { emai: string; host: string; token: string; expiry: string; }; message: string; error?: { status: number; }; }; //# sourceMappingURL=user.types.d.ts.map