export type VerifaydaPurpose = 'LOGIN' | 'VERIFY';

export interface FaydaTokenResponse {
  access_token: string;
  id_token?: string;
  token_type: string;
  expires_in?: number;
  scope?: string;
}

export interface FaydaUserInfo {
  sub: string;
  name?: string;
  'name#en'?: string;
  'name#am'?: string;
  phone_number?: string;
  'phone_number#en'?: string;
  'phone_number#am'?: string;
  phone?: string;
  email?: string;
  gender?: string;
  birthdate?: string;
  picture?: string;
  address?: Record<string, unknown>;
  [key: string]: unknown;
}

export interface NormalizedFaydaUserInfo {
  sub: string;
  // Convenience / display fields
  fullName?: string;
  phoneNumber?: string;   // standardized e.g. +251911234567
  email?: string;
  gender?: string;
  birthdate?: string;
  picture?: string;
  // Raw localized fields — preserved for IAM-identical writes
  nameEn?: string;
  nameAm?: string;
  genderEn?: string;
  genderAm?: string;
  addressEn?: string;
  addressAm?: string;
  rawPhoneNumber?: string; // unstandardized, stored in IAM metadata
}
