export const BASE_URL = process.env.NEXT_PUBLIC_API_BASE_URL!;

export const API_ENDPOINTS = {
  SEND_OTP: "/index.php/data_model/user/Registration/send_otp_geta",
  VERIFY_OTP: "/index.php/data_model/user/Registration/verify_login_otp",
  OLYMPIAD_REGISTER:
    "/index.php/data_model/user/Registration/registration_geeta",
  REGISTER: "/index.php/data_model/user/Registration/register_step1",
  HEAR_ABOUT_US: "/index.php/data_model/referral_source/submit",

  FORGOT_PASSWORD: "/index.php/data_model/user/Registration/forget_password",
  UPDATE_PROFILE: "/index.php/data_model/user/User_profile/update_user_profile",

  GET_COUNTRIES: "/index.php/data_model/user/Registration/getCountries",
  GET_STATES: "/index.php/data_model/user/Registration/getStatesByCountry",
  GET_CITIES: "/index.php/data_model/user/Registration/getCitiesByState",

  LOGIN: "/index.php/data_model/user/Registration/login_password",

  HOME_API: "/index.php/data_model/fanwall/master_hit/geta_master_hit",
  GET_BASIC_DETAIL: "/index.php/data_model/Basic_details/get_basic_details",

  SAVE_TEST_V2: "/index.php/data_model/courses/test_series_v2/save_test",
  GET_TEST_DATA: "/index.php/data_model/courses/test_series_v2/get_test_data",
  GET_TEST_RESULT:
    "/index.php/data_model/courses/test_series_v2/get_test_result",
  SAVE_TEST_OLD: "/index.php/data_model/courses/Test_series/save_test",
  TEST_CHALLENGE: "/index.php/data_model/courses/test_series_v2/test_challenge",

  GET_TEST_INSTRUCTION_DATA:
    "/index.php/data_model/courses/test_series_v2/get_test_instruction_data",
  GET_USER_RESULT: "/index.php/data_model/courses/test_series/top_list",
  GET_SOLUTION_TEST_SERIES:
    "/index.php/data_model/courses/Test_series/get_test_series_result",
  SUBMIT_QUERY: "/index.php/data_model/user/user_queries/submit_query",
  GET_TEST_LIST: "/index.php/data_model/courses/test_series_v2/get_test_list",

  COURSE_SPEAKER: "/index.php/data_model/courses/course/course_speakers_data",
  TESTIMONIAL: "/index.php/data_model/courses/course/testimonials_list",
  GET_GUIDELINE: "/index.php/data_model/courses/course/get_guidelines",

  GET_OLYMPAID_DETAILS: "/index.php/data_model/courses/course/olympiad_details",
  UPDATE_TEST_PROGRESS:
    "/index.php/data_model/courses/course/save_video_progress",
  GET_TEST_PROGRESS:
    "/index.php/data_model/courses/course/get_video_progress_data",

  GET_DONATION_LIST: "/index.php/data_model/courses/Donation/get_donation_list",
  CREATE_ORDER: "/index.php/data_model/courses/Donation/create_order",
  COMPLETE_PAYMENT: "/index.php/data_model/courses/Donation/complete_payment",
  TRANSACTION_HISTORY:
    "/index.php/data_model/courses/Donation/transaction_history",
  SEND_CONTACT_MESSAGE:
    "/index.php/data_model/user/registration/get_contact_us_geeta",

  CHAT_BOT_API: "/index.php/data_model/fanwall/Master_hit/get_chatbot_chat",

  GET_GOCOD_STATUS: "/index.php/data_model/gocod/Gocod/get_gocod_man_fi",

  GET_CHAT_HISTORY: "/index.php/data_model/fanwall/master_hit/get_chat_history",

  // Announcement APIs
  GET_ALL_ANNOUNCEMENTS:
    "/index.php/data_model/fanwall/master_hit/get_all_announcements",
  MARK_ANNOUNCEMENT_READ:
    "/index.php/data_model/fanwall/master_hit/mark_announcement_read",
  GET_ANNOUNCEMENT_READ_COUNT:
    "/index.php/data_model/fanwall/master_hit/get_announcement_read_count",

  GET_ALL_FAQ: "/index.php/data_model/faq/get_all_faqs",

  // Legal Pages API
  GET_LEGAL_PAGES: "/data_model/legal_api/get_pages",

  // Auth Check API
  CHECK_EMAIL: "/data_model/auth_check/check_email",

  // Image Upload API
  UPLOAD_IMAGE: "/index.php/upload/upload_file",
};

export function getApiUrl(endpoint: string): string {
  return `${BASE_URL}${endpoint}`;
}
