import '../env/env.dart';
import '../main.dart';
import 'box_name.dart';class AppLink {
  static String seferPaymentServer =
      'https://walletintaleq.intaleq.xyz/v1/main';
  static final String tripzPaymentServer0 = seferPaymentServer;
  static final String tripzPaymentServer = '$seferPaymentServer/ride';
  static final String tripzAlexandriaServer = Env.seferAlexandriaServer;
  static final String tripzCairoServer = Env.seferCairoServer;
  static final String tripzGizaServer = Env.seferGizaServer;
  // static final String endPoint = box.read(BoxName.serverChosen);
  // static final String server = Env.seferCairoServer;

  static String get currentCountry => box.read('countryCode') ?? 'Jordan';

  static String get server {
    switch (currentCountry) {
      case 'Syria': return 'https://api-syria.siromove.com/siro_v3';
      case 'Egypt': return 'https://api-egypt.siromove.com/siro_v3';
      case 'Jordan': return 'https://api-jordan.siromove.com/siro_v3';
      default: return 'https://api.siromove.com/siro_v3';
    }
  }
  static String get endPoint => server;
  static String get syria => 'https://api-syria.siromove.com/siro';
  
  static String get paymentServer {
    switch (currentCountry) {
      case 'Syria': return 'https://wallet-syria.siromove.com/v1/main';
      case 'Egypt': return 'https://wallet-egypt.siromove.com/v1/main';
      case 'Jordan': return 'https://wallet-jordan.siromove.com/v1/main';
      default: return 'https://wallet.siromove.com/v1/main';
    }
  }

  static String get locationServer {
    switch (currentCountry) {
      case 'Syria': return 'https://location-syria.siromove.com/siro/ride/location';
      case 'Egypt': return 'https://location-egypt.siromove.com/siro/ride/location';
      case 'Jordan': return 'https://location-jordan.siromove.com/siro/ride/location';
      default: return 'https://location.siromove.com/siro/ride/location';
    }
  }
  static String get locationServerSide => locationServer;

  static String get mapSaasRoute {
    switch (currentCountry) {
      case 'Syria': return 'https://map-syria.siromove.com/api/maps/route';
      case 'Egypt': return 'https://map-egypt.siromove.com/api/maps/route';
      case 'Jordan': return 'https://map-jordan.siromove.com/api/maps/route';
      default: return 'https://map-saas.intaleqapp.com/api/maps/route';
    }
  }

  static String get mapSaasPlaces {
    switch (currentCountry) {
      case 'Syria': return 'https://map-syria.siromove.com/api/geocoding/places';
      case 'Egypt': return 'https://map-egypt.siromove.com/api/geocoding/places';
      case 'Jordan': return 'https://map-jordan.siromove.com/api/geocoding/places';
      default: return 'https://map-saas.intaleqapp.com/api/geocoding/places';
    }
  }

  static String get routeApiBaseUrl {
    switch (currentCountry) {
      case 'Syria': return 'https://routes-syria.siromove.com/route/v1/driving';
      case 'Egypt': return 'https://routes-egypt.siromove.com/route/v1/driving';
      case 'Jordan': return 'https://routes-jordan.siromove.com/route/v1/driving';
      default: return 'https://routes.siromove.com/route/v1/driving';
    }
  }
  static String loginJwtDriver =
      "https://api.intaleq.xyz/siro/loginAdmin.php";
//=============================
//=============================
  static final getAllFingerprints =
      '$server/migration/get_all_fingerprints.php';
  static final updateFingerprintAdmin =
      '$server/migration/update_fingerprint_admin.php';
  static final getAllDriverFingerprints =
      '$server/migration/get_all_driver_fingerprints.php';
  static final updateDriverFingerprintAdmin =
      '$server/migration/update_driver_fingerprint_admin.php';
//=============================
//=============================

  static String googleMapsLink = 'https://maps.googleapis.com/maps/api/';
  static String llama = 'https://api.llama-api.com/chat/completions';
  static String gemini =
      'https://generativelanguage.googleapis.com/v1beta3/models/text-bison-001:generateText';
  static String serverMonitor = "https://tripz-egypt.com/server/monitor.php";

  static String test = "$server/test.php";
  static String loginWalletAdmin = "$seferPaymentServer/loginWalletAdmin.php";
  static String loginWalletAdminV3 = "$server/Admin/auth/loginWallet.php";
  //===============firebase==========================
  static String getTokens = "$server/ride/firebase/get.php";
  static String getInvoices = "$server/Admin/adminUser/invoice_total.php";
  static String addInvoice = "$server/Admin/adminUser/add_invoice.php";
  static String getAllTokenDrivers =
      "$server/ride/firebase/getALlTokenDrivers.php";

  static String getAllTokenPassengers =
      "$server/ride/firebase/getAllTokenPassengers.php";
  static String addTokens = "$server/ride/firebase/add.php";
  static String addTokensDriver = "$server/ride/firebase/addDriver.php";

  //=======================Wallet===================
  static String addPaymentTokenDriver =
      "$tripzPaymentServer/driverWallet/addPaymentToken.php";
  static String addSeferWallet = "$tripzPaymentServer/seferWallet/add.php";
  static String getPaymentsDashboard =
      "$seferPaymentServer/Admin/getPaymentsDashboard.php";
  static String getSeferWallet = "$tripzPaymentServer/seferWallet/get.php";
  static String addDrivePayment = "$tripzPaymentServer/payment/add.php";
  static String addFromAdmin =
      "$tripzPaymentServer/driverWallet/addFromAdmin.php";
  static String add300ToDriver =
      "$tripzPaymentServer/driverWallet/add300ToDriver.php";
  static String updatePaymetToPaid =
      "$tripzPaymentServer/payment/updatePaymetToPaid.php";
  static String wallet = '$tripzPaymentServer/passengerWallet';
  static String walletDriver = '$tripzPaymentServer/driverWallet';
  static String getAllPassengerTransaction =
      "$wallet/getAllPassengerTransaction.php";
  static String getWalletByPassenger = "$wallet/getWalletByPassenger.php";
  static String getPassengersWallet = "$wallet/get.php";
  static String getPassengerWalletArchive =
      "$wallet/getPassengerWalletArchive.php";
  static String addPassengersWallet = "$wallet/add.php";
  static String deletePassengersWallet = "$wallet/delete.php";
  static String updatePassengersWallet = "$wallet/update.php";

  static String getWalletByDriver = "$walletDriver/getWalletByDriver.php";
  static String getDriversWallet = "$walletDriver/get.php";
  static String addDriversWalletPoints = "$walletDriver/add.php";
  static String deleteDriversWallet = "$walletDriver/delete.php";
  static String updateDriversWallet = "$walletDriver/update.php";

  //=======================promo===================ride.mobile-app.store/ride/promo/get.php
  static String promo = '$server/ride/promo';
  static String getPassengersPromo = "$promo/get.php";
  static String getPromoBytody = "$promo/getPromoBytody.php";
  static String addPassengersPromo = "$promo/add.php";
  static String deletePassengersPromo = "$promo/delete.php";
  static String updatePassengersPromo = "$promo/update.php";

  ////=======================cancelRide===================
  static String ride = '$server/ride';
  static String addCancelRideFromPassenger = "$server/ride/cancelRide/add.php";
  static String cancelRide = "$server/ride/cancelRide/get.php";
//-----------------ridessss------------------
  static String addRides = "$ride/rides/add.php";
  static String getRides = "$ride/rides/get.php";
  static String getRideOrderID = "$ride/rides/getRideOrderID.php";
  static String getRideStatus = "$ride/rides/getRideStatus.php";
  static String getRideStatusBegin = "$ride/rides/getRideStatusBegin.php";
  static String getRideStatusFromStartApp =
      "$ride/rides/getRideStatusFromStartApp.php";
  static String updateRides = "$ride/rides/update.php";
  static String updateStausFromSpeed = "$ride/rides/updateStausFromSpeed.php";
  static String deleteRides = "$ride/rides/delete.php";

//-----------------DriverPayment------------------
  static String adddriverScam = "$ride/driver_scam/add.php";
  static String getdriverScam = "$ride/driver_scam/get.php";

/////////---getKazanPercent===////////////
  static String getKazanPercent = "$ride/kazan/get.php";
  static String addKazanPercent = "$ride/kazan/add.php";
  static String updateKazanPercent = "$ride/kazan/update.php";

////-----------------DriverPayment------------------
  static String addDriverpayment = "$tripzPaymentServer/payment/add.php";
  static String addDriverPaymentPoints =
      "$tripzPaymentServer/driverPayment/add.php";
  static String getDriverPaymentPoints =
      "$tripzPaymentServer/driverWallet/get.php";
  static String getDriverpaymentToday = "$tripzPaymentServer/payment/get.php";
  static String getCountRide = "$tripzPaymentServer/payment/getCountRide.php";
  static String getAllPaymentFromRide =
      "$tripzPaymentServer/payment/getAllPayment.php";
  static String getAllPaymentVisa =
      "$tripzPaymentServer/payment/getAllPaymentVisa.php";

//-----------------Passenger NotificationCaptain------------------
  static String addNotificationPassenger =
      "$ride/notificationPassenger/add.php";
  static String send_whatsapp_message =
      "$server/Admin/send_whatsapp_message.php";
  static String getNotificationPassenger =
      "$ride/notificationPassenger/get.php";
  static String updateNotificationPassenger =
      "$ride/notificationPassenger/update.php";

//-----------------Driver NotificationCaptain------------------
  static String addNotificationCaptain = "$ride/notificationCaptain/add.php";
  static String addWaitingRide = "$ride/notificationCaptain/addWaitingRide.php";
  static String getRideWaiting = "$ride/notificationCaptain/getRideWaiting.php";
  static String getNotificationCaptain = "$ride/notificationCaptain/get.php";
  static String updateNotificationCaptain =
      "$ride/notificationCaptain/update.php";
  static String deleteNotificationCaptain =
      "$ride/notificationCaptain/delete.php";
  //-----------------Api Key------------------
  static String addApiKey = "$ride/apiKey/add.php";
  static String getApiKey = "$ride/apiKey/get.php";
  static String getCnMap = "$server/auth/cnMap.php";
  static String updateApiKey = "$ride/apiKey/update.php";
  static String deleteApiKey = "$ride/apiKey/delete.php";

//-----------------Feed Back------------------
  static String addFeedBack = "$ride/feedBack/add.php";
  static String getFeedBack = "$ride/feedBack/get.php";
  static String updateFeedBack = "$ride/feedBack/updateFeedBack.php";

  //-----------------Tips------------------
  static String addTips = "$ride/tips/add.php";
  static String getTips = "$ride/tips/get.php";
  static String updateTips = "$ride/tips/update.php";

//-----------------Help Center------------------
  static String addhelpCenter = "$ride/helpCenter/add.php";
  static String gethelpCenter = "$ride/helpCenter/get.php";
  static String getByIdhelpCenter = "$ride/helpCenter/getById.php";
  static String updatehelpCenter = "$ride/helpCenter/update.php";
  static String deletehelpCenter = "$ride/helpCenter/delete.php";

  //-----------------license------------------
  static String addLicense = "$ride/license/add.php";
  static String getLicense = "$ride/license/get.php";
  static String updateLicense = "$ride/license/updateFeedBack.php";
//-----------------RegisrationCar------------------
  static String addRegisrationCar = "$ride/RegisrationCar/add.php";
  static String getRegisrationCar = "$ride/RegisrationCar/get.php";
  static String updateRegisrationCar = "$ride/RegisrationCar/update.php";

//-----------------DriverOrder------------------

  static String addDriverOrder = "$ride/driver_order/add.php";
  static String getDriverOrder = "$ride/driver_order/get.php";
  static String getOrderCancelStatus =
      "$ride/driver_order/getOrderCancelStatus.php";
  static String updateDriverOrder = "$ride/driver_order/update.php";
  static String deleteDriverOrder = "$ride/driver_order/delete.php";

  // =====================================
  static String addRateToPassenger = "$ride/rate/add.php";
  static String addRateToDriver = "$ride/rate/addRateToDriver.php";
  static String getDriverRate = "$ride/rate/getDriverRate.php";
  static String getPassengerRate = "$ride/rate/getPassengerRate.php";

  ////////////////emails ============//
  static String sendEmailToPassengerForTripDetails =
      "$ride/rides/emailToPassengerTripDetail.php";
  static String sendEmailToDrivertransaction =
      "$server/Admin/sendEmailToDrivertransaction.php";

// ===========================================
  static String pathImage = "$server/upload/types/";
  static String uploadImage = "$server/uploadImage.php";
  static String uploadImage1 = "$server/uploadImage1.php";
  static String uploadImagePortrate = "$server/uploadImagePortrate.php";
  static String uploadImageType = "$server/uploadImageType.php";
//=============egypt documents ==============
  static String uploadEgyptidFront =
      "$server/EgyptDocuments/uploadEgyptidFront.php";
  static String uploadEgypt = "$server/uploadEgypt.php";

  //==================certifcate==========
  static String location = locationServer;
  static String getCarsLocationByPassenger = "$location/get.php";
  static String getFemalDriverLocationByPassenger =
      "$location/getFemalDriver.php";
  static String getDriverCarsLocationToPassengerAfterApplied =
      "$location/getDriverCarsLocationToPassengerAfterApplied.php";
  static String addCarsLocationByPassenger = "$location/add.php";
  static String deleteCarsLocationByPassenger = "$location/delete.php";
  static String updateCarsLocationByPassenger = "$location/update.php";
  static String getTotalDriverDuration = "$location/getTotalDriverDuration.php";
  static String getTotalDriverDurationToday =
      "$location/getTotalDriverDurationToday.php";

  //==================Blog=============
  static String profile = '$server/ride/profile';
  static String getprofile = "$profile/get.php";
  static String getCaptainProfile = "$profile/getCaptainProfile.php";
  static String addprofile = "$profile/add.php";
  static String deleteprofile = "$profile/delete.php";
  static String updateprofile = "$profile/update.php";

  //===================Auth============

  static String auth = '$server/auth';
  static String login = "$auth/login.php";
  static String signUp = "$auth/signup.php";
  static String sendVerifyEmail = "$auth/sendVerifyEmail.php";
  static String passengerRemovedAccountEmail =
      "$auth/passengerRemovedAccountEmail.php";
  static String verifyEmail = "$auth/verifyEmail.php";
//===================Auth Captin============
  static String authCaptin = '$server/auth/captin';
  static String loginCaptin = "$authCaptin/login.php";
  static String signUpCaptin = "$authCaptin/register.php";
  static String sendVerifyEmailCaptin = "$authCaptin/sendVerifyEmail.php";
  static String verifyEmailCaptin = "$authCaptin/verifyEmail.php";
  static String removeUser = "$authCaptin/removeAccount.php";
  static String deletecaptainAccounr = "$authCaptin/deletecaptainAccounr.php";
  static String updateAccountBank = "$authCaptin/updateAccountBank.php";
  static String getAccount = "$authCaptin/getAccount.php";

  //===================Admin Captin============
  static String getDriversPhonesAndTokens =
      "$server/Admin/AdminCaptain/getDriversPhonesAndTokens.php";
  static String getPassengerDetailsByPassengerID =
      "$server/Admin/getPassengerDetailsByPassengerID.php";
  static String getPassengerDetails = "$server/Admin/getPassengerDetails.php";
  static String admin_delete_and_blacklist_passenger =
      "$server/Admin/passenger/admin_delete_and_blacklist_passenger.php";
  static String admin_update_passenger =
      "$server/Admin/passenger/admin_update_passenger.php";
  static String admin_unblacklist =
      "$server/Admin/passenger/admin_unblacklist.php";
  static String admin_get_rides_by_phone =
      "$server/Admin/rides/admin_get_rides_by_phone.php";
  static String admin_update_ride_status =
      "$server/Admin/rides/admin_update_ride_status.php";
  static String getPassengerbyEmail = "$server/Admin/getPassengerbyEmail.php";
  static String updateDriverFromAdmin =
      "$server/Admin/driver/updateDriverFromAdmin.php";
  static String find_driver_by_phone =
      "$server/Admin/driver/find_driver_by_phone.php";
  static String getDriversPending =
      "$server/auth/syria/driver/drivers_pending_list.php";
  static String getDriverDetails =
      "$server/auth/syria/driver/driver_details.php";
  static String deleteCaptain = "$server/Admin/driver/deleteCaptain.php";
  static String addAdminUser = "$server/Admin/adminUser/add.php";
  static String addStaff = "$server/Admin/Staff/add.php";
  static String getdashbord = "$server/Admin/dashbord.php";
  static String paymentServerV2 = 'https://walletintaleq.intaleq.xyz/v2/main';
  static String realtimeDashboardV2 = "$server/Admin/v2/realtime_dashboard.php";
  static String smartAlertsV2 = "$server/Admin/v2/smart_alerts.php";
  static String growthV2 = "$server/Admin/v2/analytics/growth.php";
  static String revenueV2 = "$server/Admin/v2/analytics/revenue.php";
  static String driverRankingV2 = "$server/Admin/v2/analytics/driver_ranking.php";
  static String settlementsV2 = "$paymentServerV2/Admin/v2/financial/settlements.php";
  static String financialStatsV2 = "$paymentServerV2/Admin/v2/financial/stats.php";
  static String dashboardWalletV2 = "$paymentServerV2/Admin/v2/financial/dashboard_wallet.php";
  static String auditLogsV2 = "$server/Admin/v2/security/audit_logs.php";
  static String blacklistManager = "$server/Admin/v2/quality/blacklist_manager.php";
  static String driverScorecard = "$server/Admin/v2/quality/driver_scorecard.php";
  static String getEmployee = "$server/Admin/employee/get.php";
  static String getBestDriver = "$server/Admin/driver/getBestDriver.php";
  static String getBestDriverGiza =
      "https://gizasefer.online/sefer/Admin/driver/getBestDriver.php";
  static String getBestDriverAlexandria =
      "$tripzAlexandriaServer/Admin/driver/getBestDriver.php";
  static String deleteRecord = "$server/Admin/driver/deleteRecord.php";
  static String addEmployee = "$server/Admin/employee/add.php";
  static String getdashbordPayment = "$server/Admin/dashbordPayment.php";
  static String getAdminUser = "$server/Admin/adminUser/get.php";
  static String getCaptainDetailsByEmailOrIDOrPhone =
      "$server/Admin/AdminCaptain/getCaptainDetailsByEmailOrIDOrPhone.php";
  static String getCaptainDetails = "$server/Admin/AdminCaptain/get.php";
  static String getVisaForEachDriver =
      "$seferPaymentServer/Admin/getVisaForEachDriver.php";
  static String getRidesPerMonth =
      "$server/Admin/AdminRide/getRidesPerMonth.php";
  static String getRidesDetails = "$server/Admin/AdminRide/get.php";
  static String getPassengersStatic = "$serviceApp/getPassengersStatic.php";
  static String getRidesStatic = "$serviceApp/getRidesStatic.php";
  static String getEmployeeStatic = "$serviceApp/getEmployeeStatic.php";
  static String getNotesForEmployee = "$serviceApp/getNotesForEmployee.php";
  static String getEmployeeDriverAfterCallingRegister =
      "$serviceApp/getEmployeeDriverAfterCallingRegister.php";
  static String getEditorStatsCalls = "$serviceApp/getEditorStatsCalls.php";
  static String getdriverstotalMonthly =
      "$serviceApp/getdriverstotalMonthly.php";

////////////////////////
  static String serviceApp = "$server/serviceapp";
  static String editCarPlate = "$serviceApp/editCarPlate.php";
  static String getComplaintAllData = "$serviceApp/getComplaintAllData.php";
  static String getComplaintAllDataForDriver =
      "$serviceApp/getComplaintAllDataForDriver.php";
  static String addCriminalDocuments = "$authCaptin/addCriminalDocuments.php";
  static String getPassengersByPhone =
      "$server/serviceApp/getPassengersByPhone.php";
  static String getDriverByPhone = "$serviceApp/getDriverByPhone.php";
  static String getNewDriverRegister = "$serviceApp/getNewDriverRegister.php";
  static String addWelcomeDriverNote = "$serviceApp/addWelcomeDriverNote.php";
  static String getDriverNotCompleteRegistration =
      "$serviceApp/getDriverNotCompleteRegistration.php";
  static String getPassengersNotCompleteRegistration =
      "$serviceApp/getPassengersNotCompleteRegistration.php";
  static String addNotesDriver = "$serviceApp/addNotesDriver.php";
  static String getCarPlateNotEdit = "$serviceApp/getCarPlateNotEdit.php";
  static String addNotesPassenger = "$serviceApp/addNotesPassenger.php";
  static String getPackages = "$serviceApp/getPackages.php";
  static String updatePackages = "$serviceApp/updatePackages.php";
  //////
  static String sendSms = "https://sms.kazumi.me/api/sms/send-sms";
  static String senddlr = "https://sms.kazumi.me/api/sms/send-dlr";
  static String sendvalidity = "https://sms.kazumi.me/api/sms/send-validity";
  static String sendmany = "https://sms.kazumi.me/api/sms/send-many";
  static String checkCredit = "https://sms.kazumi.me/api/sms/check-credit";
  static String getSender = "$server/auth/sms/getSender.php";
  static String checkStatus = "https://sms.kazumi.me/api/sms/check-status";
  static String updatePhoneInvalidSMSPassenger =
      "$server/auth/sms/updatePhoneInvalidSMSPassenger.php";
}
