-- phpMyAdmin SQL Dump
-- version 5.2.1
-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: Aug 31, 2026 at 11:36 AM
-- Server version: 10.4.32-MariaDB
-- PHP Version: 8.2.12

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;

--
-- Database: `velora_dating`
--

-- --------------------------------------------------------

--
-- Table structure for table `admin_activity_logs`
--

CREATE TABLE `admin_activity_logs` (
  `id` bigint(20) NOT NULL,
  `admin_id` bigint(20) UNSIGNED DEFAULT NULL,
  `action` varchar(150) DEFAULT NULL,
  `target_type` varchar(50) DEFAULT NULL,
  `target_id` bigint(20) DEFAULT NULL,
  `metadata` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`metadata`)),
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `admin_activity_logs`
--

INSERT INTO `admin_activity_logs` (`id`, `admin_id`, `action`, `target_type`, `target_id`, `metadata`, `created_at`) VALUES
(1, 31, 'Manual premium activation', 'user', 16, '{\"days\":30,\"reference\":\"ADMIN-MANUAL-AC4FDE3F\",\"note\":\"\"}', '2026-08-31 11:23:19');

-- --------------------------------------------------------

--
-- Table structure for table `blocks`
--

CREATE TABLE `blocks` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `blocked_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `boosts`
--

CREATE TABLE `boosts` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `starts_at` datetime DEFAULT NULL,
  `ends_at` datetime DEFAULT NULL,
  `status` enum('active','used','expired') DEFAULT 'active',
  `source` varchar(40) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `chat_presence`
--

CREATE TABLE `chat_presence` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `peer_id` bigint(20) UNSIGNED NOT NULL,
  `typing_at` datetime DEFAULT NULL,
  `last_seen_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `credit_transactions`
--

CREATE TABLE `credit_transactions` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `amount` int(11) DEFAULT NULL,
  `reason` varchar(100) DEFAULT NULL,
  `reference` varchar(190) DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `credit_wallets`
--

CREATE TABLE `credit_wallets` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `balance` int(11) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `credit_wallets`
--

INSERT INTO `credit_wallets` (`user_id`, `balance`) VALUES
(16, 0),
(17, 0),
(18, 0),
(19, 0),
(20, 0),
(21, 0),
(22, 0),
(23, 0),
(24, 0),
(25, 0),
(26, 0),
(27, 0),
(28, 0),
(29, 0),
(30, 0),
(31, 0);

-- --------------------------------------------------------

--
-- Table structure for table `events`
--

CREATE TABLE `events` (
  `id` bigint(20) NOT NULL,
  `title` varchar(150) DEFAULT NULL,
  `description` text DEFAULT NULL,
  `city` varchar(100) DEFAULT NULL,
  `venue` varchar(200) DEFAULT NULL,
  `starts_at` datetime DEFAULT NULL,
  `ends_at` datetime DEFAULT NULL,
  `organizer_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `status` enum('draft','published','cancelled') DEFAULT 'draft'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `icebreaker_suggestions`
--

CREATE TABLE `icebreaker_suggestions` (
  `id` int(11) NOT NULL,
  `category` varchar(40) DEFAULT 'general',
  `line` varchar(500) NOT NULL,
  `active` tinyint(4) DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `icebreaker_suggestions`
--

INSERT INTO `icebreaker_suggestions` (`id`, `category`, `line`, `active`) VALUES
(1, 'general', 'Hey {name}! Your profile made me smile — what\'s something fun you\'re into this week?', 1),
(2, 'general', 'Hi {name} 👋 Random question: coffee date or sunset walk?', 1),
(3, 'general', 'Hey! I noticed we might have a spark — what\'s your go-to weekend vibe?', 1),
(4, 'hobbies', 'Your hobbies caught my eye — tell me more about {hobby}?', 1),
(5, 'hobbies', 'Fellow {hobby} fan here. What got you into it?', 1),
(6, 'city', 'Hey from nearby {city}! Ever found a hidden gem spot around there?', 1),
(7, 'city', 'So you\'re in {city} — any must-try food place you\'d recommend?', 1),
(8, 'goal', 'I saw you\'re looking for {goal}. Honest first question: what does a great connection look like for you?', 1),
(9, 'general', 'Hi {name}! If we matched over one shared interest, which one would you pick first?', 1),
(10, 'general', 'Hey! Quick icebreaker: pineapple on pizza — yes or never?', 1);

-- --------------------------------------------------------

--
-- Table structure for table `interests`
--

CREATE TABLE `interests` (
  `id` int(11) NOT NULL,
  `name` varchar(80) NOT NULL,
  `active` tinyint(4) DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `interests`
--

INSERT INTO `interests` (`id`, `name`, `active`) VALUES
(1, 'Yoga', 1),
(2, 'Fitness', 1),
(3, 'Nightlife', 1),
(4, 'Fashion', 1),
(5, 'Pets', 1),
(6, 'Wine', 1),
(7, 'Coffee', 1),
(8, 'Startup', 1),
(9, 'Volunteering', 1),
(10, 'Football', 1),
(11, 'Netflix', 1),
(12, 'Podcasts', 1),
(13, 'Beach', 1),
(14, 'Camping', 1),
(15, 'Karaoke', 1),
(16, 'Board games', 1),
(33, 'Travel', 1),
(34, 'Music', 1),
(35, 'Movies', 1),
(36, 'Sports', 1),
(37, 'Food', 1),
(38, 'Photography', 1),
(39, 'Reading', 1),
(40, 'Technology', 1),
(41, 'Art', 1),
(42, 'Nature', 1),
(43, 'Gaming', 1),
(44, 'Business', 1),
(45, 'Cooking', 1),
(46, 'Hiking', 1),
(47, 'Dance', 1);

-- --------------------------------------------------------

--
-- Table structure for table `likes`
--

CREATE TABLE `likes` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `target_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `matches`
--

CREATE TABLE `matches` (
  `id` bigint(20) NOT NULL,
  `user_one_id` bigint(20) UNSIGNED DEFAULT NULL,
  `user_two_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `messages`
--

CREATE TABLE `messages` (
  `id` bigint(20) NOT NULL,
  `sender_id` bigint(20) UNSIGNED DEFAULT NULL,
  `receiver_id` bigint(20) UNSIGNED DEFAULT NULL,
  `body` text NOT NULL,
  `is_read` tinyint(4) DEFAULT 0,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `notifications`
--

CREATE TABLE `notifications` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `type` varchar(50) DEFAULT NULL,
  `title` varchar(150) DEFAULT NULL,
  `body` varchar(500) DEFAULT NULL,
  `is_read` tinyint(4) DEFAULT 0,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `notifications`
--

INSERT INTO `notifications` (`id`, `user_id`, `type`, `title`, `body`, `is_read`, `created_at`) VALUES
(2, 16, 'system', 'Premium activated', 'An administrator activated your Monthly Access for 30 days. Inbox and messaging are unlocked.', 0, '2026-08-31 11:23:19');

-- --------------------------------------------------------

--
-- Table structure for table `notification_preferences`
--

CREATE TABLE `notification_preferences` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `email_enabled` tinyint(4) DEFAULT 1,
  `push_enabled` tinyint(4) DEFAULT 1,
  `match_enabled` tinyint(4) DEFAULT 1,
  `message_enabled` tinyint(4) DEFAULT 1,
  `marketing_enabled` tinyint(4) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `notification_preferences`
--

INSERT INTO `notification_preferences` (`user_id`, `email_enabled`, `push_enabled`, `match_enabled`, `message_enabled`, `marketing_enabled`) VALUES
(16, 1, 1, 1, 1, 0),
(31, 1, 1, 1, 1, 0);

-- --------------------------------------------------------

--
-- Table structure for table `passes`
--

CREATE TABLE `passes` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `target_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `passes`
--

INSERT INTO `passes` (`id`, `user_id`, `target_user_id`, `created_at`) VALUES
(3, 31, 27, '2026-08-31 11:26:39');

-- --------------------------------------------------------

--
-- Table structure for table `payment_settings`
--

CREATE TABLE `payment_settings` (
  `id` int(11) NOT NULL DEFAULT 1,
  `mpesa_enabled` tinyint(4) DEFAULT 0,
  `mpesa_env` enum('sandbox','live') DEFAULT 'sandbox',
  `mpesa_consumer_key` varchar(255) DEFAULT '',
  `mpesa_consumer_secret` varchar(255) DEFAULT '',
  `mpesa_shortcode` varchar(30) DEFAULT '',
  `mpesa_passkey` varchar(255) DEFAULT '',
  `mpesa_callback_url` varchar(500) DEFAULT '',
  `card_enabled` tinyint(4) DEFAULT 0,
  `card_provider` varchar(50) DEFAULT 'stripe',
  `card_publishable_key` varchar(255) DEFAULT '',
  `card_secret_key` varchar(255) DEFAULT '',
  `card_webhook_secret` varchar(255) DEFAULT '',
  `monthly_price_kes` decimal(10,2) DEFAULT 500.00,
  `trial_hours` int(11) DEFAULT 72,
  `updated_at` datetime DEFAULT NULL,
  `updated_by` bigint(20) UNSIGNED DEFAULT NULL,
  `mpesa_strict_ip` tinyint(4) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `payment_settings`
--

INSERT INTO `payment_settings` (`id`, `mpesa_enabled`, `mpesa_env`, `mpesa_consumer_key`, `mpesa_consumer_secret`, `mpesa_shortcode`, `mpesa_passkey`, `mpesa_callback_url`, `card_enabled`, `card_provider`, `card_publishable_key`, `card_secret_key`, `card_webhook_secret`, `monthly_price_kes`, `trial_hours`, `updated_at`, `updated_by`, `mpesa_strict_ip`) VALUES
(1, 1, 'sandbox', '', '', '', '', '', 1, 'stripe', '', '', '', 500.00, 72, '2026-08-31 10:06:03', 1, 1);

-- --------------------------------------------------------

--
-- Table structure for table `payment_transactions`
--

CREATE TABLE `payment_transactions` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `plan_id` int(11) DEFAULT NULL,
  `amount` decimal(10,2) DEFAULT NULL,
  `currency` varchar(10) DEFAULT NULL,
  `provider` varchar(50) DEFAULT NULL,
  `reference` varchar(190) DEFAULT NULL,
  `phone` varchar(30) DEFAULT NULL,
  `checkout_request_id` varchar(100) DEFAULT NULL,
  `merchant_request_id` varchar(100) DEFAULT NULL,
  `status` enum('pending','paid','failed','refunded') DEFAULT 'pending',
  `metadata` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`metadata`)),
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `payment_transactions`
--

INSERT INTO `payment_transactions` (`id`, `user_id`, `plan_id`, `amount`, `currency`, `provider`, `reference`, `phone`, `checkout_request_id`, `merchant_request_id`, `status`, `metadata`, `created_at`) VALUES
(1, 16, 10, 500.00, 'KES', 'admin_manual', 'ADMIN-MANUAL-AC4FDE3F', NULL, NULL, NULL, 'paid', '{\"note\":\"\",\"days\":30,\"admin_id\":31}', '2026-08-31 11:23:19');

-- --------------------------------------------------------

--
-- Table structure for table `profile_prompts`
--

CREATE TABLE `profile_prompts` (
  `id` int(11) NOT NULL,
  `prompt` varchar(255) NOT NULL,
  `active` tinyint(4) DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `promo_codes`
--

CREATE TABLE `promo_codes` (
  `id` int(11) NOT NULL,
  `code` varchar(50) DEFAULT NULL,
  `discount_percent` decimal(5,2) DEFAULT NULL,
  `max_uses` int(11) DEFAULT NULL,
  `used_count` int(11) DEFAULT 0,
  `expires_at` datetime DEFAULT NULL,
  `active` tinyint(4) DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `reports`
--

CREATE TABLE `reports` (
  `id` bigint(20) NOT NULL,
  `reporter_id` bigint(20) UNSIGNED DEFAULT NULL,
  `reported_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `reason` varchar(100) DEFAULT NULL,
  `details` text DEFAULT NULL,
  `status` enum('open','reviewing','resolved','dismissed') DEFAULT 'open',
  `created_at` datetime DEFAULT current_timestamp(),
  `resolved_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `session_hash` varchar(255) DEFAULT NULL,
  `ip_hash` varchar(255) DEFAULT NULL,
  `user_agent` varchar(500) DEFAULT NULL,
  `last_seen_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `sessions`
--

INSERT INTO `sessions` (`id`, `user_id`, `session_hash`, `ip_hash`, `user_agent`, `last_seen_at`) VALUES
(1, 31, '54557c7b3b8bc62e08ad4eca6dc36275707a9cec9c094c419121e36af29e7895', 'eff8e7ca506627fe15dda5e0e512fcaad70b6d520f37cc76597fdb4f2d83a1a3', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', '2026-08-31 11:10:41'),
(2, 16, 'da19b45a473dba1d55ec13bf0d692646880fa0e08018caa80d762c520af26382', 'eff8e7ca506627fe15dda5e0e512fcaad70b6d520f37cc76597fdb4f2d83a1a3', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', '2026-08-31 11:24:21');

-- --------------------------------------------------------

--
-- Table structure for table `subscription_plans`
--

CREATE TABLE `subscription_plans` (
  `id` int(11) NOT NULL,
  `name` varchar(80) DEFAULT NULL,
  `price_kes` decimal(10,2) DEFAULT NULL,
  `billing_period` varchar(30) DEFAULT NULL,
  `description` varchar(255) DEFAULT NULL,
  `features` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL CHECK (json_valid(`features`)),
  `active` tinyint(4) DEFAULT 1,
  `sort_order` int(11) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `subscription_plans`
--

INSERT INTO `subscription_plans` (`id`, `name`, `price_kes`, `billing_period`, `description`, `features`, `active`, `sort_order`) VALUES
(10, 'Monthly Access', 500.00, 'month', 'Full access to discovery, matches, and messaging. Required after free trial. Inbox is paid-only.', '[\"Full discovery access\",\"Unlimited likes\",\"Matches\",\"Inbox and messaging\",\"Blue verified badge\",\"Priority visibility\"]', 1, 0);

-- --------------------------------------------------------

--
-- Table structure for table `super_likes`
--

CREATE TABLE `super_likes` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `target_user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `users`
--

CREATE TABLE `users` (
  `id` bigint(20) UNSIGNED NOT NULL,
  `name` varchar(80) NOT NULL,
  `email` varchar(190) NOT NULL,
  `password_hash` varchar(255) NOT NULL,
  `dob` date NOT NULL,
  `role` enum('user','moderator','support','finance','verification','admin') DEFAULT 'user',
  `status` enum('active','paused','suspended','banned') DEFAULT 'active',
  `country` varchar(80) DEFAULT 'Kenya',
  `phone` varchar(30) DEFAULT NULL,
  `email_verified_at` datetime DEFAULT NULL,
  `phone_verified_at` datetime DEFAULT NULL,
  `last_seen_at` datetime DEFAULT NULL,
  `created_at` datetime NOT NULL DEFAULT current_timestamp(),
  `trial_ends_at` datetime DEFAULT NULL,
  `paid_until` datetime DEFAULT NULL,
  `is_verified_paid` tinyint(4) DEFAULT 0,
  `updated_at` datetime DEFAULT NULL,
  `deleted_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `users`
--

INSERT INTO `users` (`id`, `name`, `email`, `password_hash`, `dob`, `role`, `status`, `country`, `phone`, `email_verified_at`, `phone_verified_at`, `last_seen_at`, `created_at`, `trial_ends_at`, `paid_until`, `is_verified_paid`, `updated_at`, `deleted_at`) VALUES
(16, 'Amina Okello', 'demo1@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1996-03-12', 'user', 'active', 'Kenya', '254712000001', '2026-08-31 11:06:42', NULL, '2026-08-31 11:24:21', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:23:19', 1, '2026-08-31 11:23:19', NULL),
(17, 'Brian Mwangi', 'demo2@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1994-07-22', 'user', 'active', 'Kenya', '254712000002', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(18, 'Chloe Wanjiku', 'demo3@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1998-11-05', 'user', 'active', 'Kenya', '254712000003', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(19, 'David Otieno', 'demo4@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1992-01-18', 'user', 'active', 'Uganda', '254712000004', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(20, 'Elena Njeri', 'demo5@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1997-05-30', 'user', 'active', 'Uganda', '254712000005', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(21, 'Felix Kamau', 'demo6@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1993-09-14', 'user', 'active', 'Tanzania', '254712000006', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(22, 'Grace Achieng', 'demo7@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1999-02-08', 'user', 'active', 'Nigeria', '254712000007', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(23, 'Hassan Ali', 'demo8@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1991-12-25', 'user', 'active', 'Nigeria', '254712000008', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(24, 'Ivy Chebet', 'demo9@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1995-08-19', 'user', 'active', 'South Africa', '254712000009', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(25, 'James Kariuki', 'demo10@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1990-04-03', 'user', 'active', 'United Kingdom', '254712000010', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(26, 'Kevin Omondi', 'demo11@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1996-06-21', 'user', 'active', 'United Kingdom', '254712000011', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(27, 'Linda Muthoni', 'demo12@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1998-10-11', 'user', 'active', 'United States', '254712000012', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(28, 'Maria Santos', 'demo13@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1994-03-27', 'user', 'active', 'United States', '254712000013', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(29, 'Noah Kimani', 'demo14@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1997-01-09', 'user', 'active', 'United Arab Emirates', '254712000014', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(30, 'Olivia Wairimu', 'demo15@velora.local', '$2y$12$XF1ktERgYTJYSyQRBY0xgu5h.zoKXZ0i8XnOymmVvB2DSlUKtloTG', '1995-12-01', 'user', 'active', 'India', '254712000015', '2026-08-31 11:06:42', NULL, '2026-08-31 11:06:42', '2026-08-31 11:06:42', '2026-09-03 11:06:42', '2026-09-30 11:06:42', 1, NULL, NULL),
(31, 'Cliff Baiso', 'cliffbaiso@gmail.com', '$2y$10$XbqTtT2Eo6LYm8IUg9sfduWJuYVqM.QUWGKU9z5cRCHbN1myQUxiy', '1987-01-01', 'admin', 'active', 'Kenya', NULL, '2026-08-31 11:10:32', NULL, '2026-08-31 11:10:41', '2026-08-31 11:10:32', '2036-08-31 11:10:32', '2036-08-31 11:10:32', 1, NULL, NULL);

-- --------------------------------------------------------

--
-- Table structure for table `user_interests`
--

CREATE TABLE `user_interests` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `interest_id` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `user_photos`
--

CREATE TABLE `user_photos` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `path` varchar(255) NOT NULL,
  `is_primary` tinyint(4) DEFAULT 0,
  `moderation_status` enum('pending','approved','rejected') DEFAULT 'approved',
  `created_at` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `user_photos`
--

INSERT INTO `user_photos` (`id`, `user_id`, `path`, `is_primary`, `moderation_status`, `created_at`) VALUES
(121, 16, 'uploads/profiles/demo_w1_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(122, 16, 'uploads/profiles/demo_w1_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(123, 16, 'uploads/profiles/demo_w1_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(124, 16, 'uploads/profiles/demo_w1_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(125, 17, 'uploads/profiles/demo_m1_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(126, 17, 'uploads/profiles/demo_m1_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(127, 17, 'uploads/profiles/demo_m1_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(128, 17, 'uploads/profiles/demo_m1_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(129, 18, 'uploads/profiles/demo_w2_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(130, 18, 'uploads/profiles/demo_w2_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(131, 18, 'uploads/profiles/demo_w2_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(132, 18, 'uploads/profiles/demo_w2_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(133, 19, 'uploads/profiles/demo_m2_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(134, 19, 'uploads/profiles/demo_m2_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(135, 19, 'uploads/profiles/demo_m2_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(136, 19, 'uploads/profiles/demo_m2_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(137, 20, 'uploads/profiles/demo_w3_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(138, 20, 'uploads/profiles/demo_w3_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(139, 20, 'uploads/profiles/demo_w3_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(140, 20, 'uploads/profiles/demo_w3_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(141, 21, 'uploads/profiles/demo_m3_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(142, 21, 'uploads/profiles/demo_m3_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(143, 21, 'uploads/profiles/demo_m3_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(144, 21, 'uploads/profiles/demo_m3_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(145, 22, 'uploads/profiles/demo_w4_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(146, 22, 'uploads/profiles/demo_w4_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(147, 22, 'uploads/profiles/demo_w4_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(148, 22, 'uploads/profiles/demo_w4_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(149, 23, 'uploads/profiles/demo_m4_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(150, 23, 'uploads/profiles/demo_m4_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(151, 23, 'uploads/profiles/demo_m4_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(152, 23, 'uploads/profiles/demo_m4_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(153, 24, 'uploads/profiles/demo_w5_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(154, 24, 'uploads/profiles/demo_w5_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(155, 24, 'uploads/profiles/demo_w5_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(156, 24, 'uploads/profiles/demo_w5_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(157, 25, 'uploads/profiles/demo_m1_b.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(158, 25, 'uploads/profiles/demo_m1_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(159, 25, 'uploads/profiles/demo_m1_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(160, 25, 'uploads/profiles/demo_m1_a.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(161, 26, 'uploads/profiles/demo_m2_b.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(162, 26, 'uploads/profiles/demo_m2_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(163, 26, 'uploads/profiles/demo_m2_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(164, 26, 'uploads/profiles/demo_m2_a.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(165, 27, 'uploads/profiles/demo_w6_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(166, 27, 'uploads/profiles/demo_w6_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(167, 27, 'uploads/profiles/demo_w6_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(168, 27, 'uploads/profiles/demo_w6_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(169, 28, 'uploads/profiles/demo_w7_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(170, 28, 'uploads/profiles/demo_w7_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(171, 28, 'uploads/profiles/demo_w7_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(172, 28, 'uploads/profiles/demo_w7_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(173, 29, 'uploads/profiles/demo_m3_b.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(174, 29, 'uploads/profiles/demo_m3_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(175, 29, 'uploads/profiles/demo_m3_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(176, 29, 'uploads/profiles/demo_m3_a.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(177, 30, 'uploads/profiles/demo_w8_a.jpg', 1, 'approved', '2026-08-31 11:27:36'),
(178, 30, 'uploads/profiles/demo_w8_b.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(179, 30, 'uploads/profiles/demo_w8_c.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(180, 30, 'uploads/profiles/demo_w8_d.jpg', 0, 'approved', '2026-08-31 11:27:36'),
(181, 31, 'uploads/profiles/fae1c169fcc8c246260d04b6.jpg', 1, 'approved', '2026-08-31 11:39:32');

-- --------------------------------------------------------

--
-- Table structure for table `user_preferences`
--

CREATE TABLE `user_preferences` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `min_age` tinyint(4) DEFAULT 18,
  `max_age` tinyint(4) DEFAULT 99,
  `max_distance_km` int(11) DEFAULT 50,
  `show_gender` varchar(80) DEFAULT 'Everyone',
  `relationship_goals` varchar(255) DEFAULT '',
  `dealbreakers` tinyint(4) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `user_preferences`
--

INSERT INTO `user_preferences` (`user_id`, `min_age`, `max_age`, `max_distance_km`, `show_gender`, `relationship_goals`, `dealbreakers`) VALUES
(16, 22, 45, 5000, 'Everyone', '', 0),
(17, 22, 45, 5000, 'Everyone', '', 0),
(18, 22, 45, 5000, 'Everyone', '', 0),
(19, 22, 45, 5000, 'Everyone', '', 0),
(20, 22, 45, 5000, 'Everyone', '', 0),
(21, 22, 45, 5000, 'Everyone', '', 0),
(22, 22, 45, 5000, 'Everyone', '', 0),
(23, 22, 45, 5000, 'Everyone', '', 0),
(24, 22, 45, 5000, 'Everyone', '', 0),
(25, 22, 45, 5000, 'Everyone', '', 0),
(26, 22, 45, 5000, 'Everyone', '', 0),
(27, 22, 45, 5000, 'Everyone', '', 0),
(28, 22, 45, 5000, 'Everyone', '', 0),
(29, 22, 45, 5000, 'Everyone', '', 0),
(30, 22, 45, 5000, 'Everyone', '', 0),
(31, 18, 99, 50, 'Everyone', '', 0);

-- --------------------------------------------------------

--
-- Table structure for table `user_profiles`
--

CREATE TABLE `user_profiles` (
  `user_id` bigint(20) UNSIGNED NOT NULL,
  `bio` varchar(500) DEFAULT '',
  `hobbies` varchar(500) DEFAULT '',
  `likes_text` varchar(500) DEFAULT '',
  `custom_interests` varchar(500) DEFAULT '',
  `city` varchar(100) DEFAULT '',
  `location_label` varchar(190) DEFAULT '',
  `relationship_goal` varchar(60) DEFAULT 'Long-term',
  `gender` varchar(60) DEFAULT '',
  `orientation` varchar(80) DEFAULT '',
  `pronouns` varchar(60) DEFAULT '',
  `distance_km` int(11) DEFAULT 50,
  `profile_completion` tinyint(4) DEFAULT 0,
  `visibility` tinyint(4) DEFAULT 1,
  `show_phone` tinyint(4) DEFAULT 0,
  `show_distance` tinyint(4) DEFAULT 1,
  `incognito` tinyint(4) DEFAULT 0,
  `travel_city` varchar(100) DEFAULT NULL,
  `latitude` decimal(10,7) DEFAULT NULL,
  `longitude` decimal(10,7) DEFAULT NULL,
  `updated_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `user_profiles`
--

INSERT INTO `user_profiles` (`user_id`, `bio`, `hobbies`, `likes_text`, `custom_interests`, `city`, `location_label`, `relationship_goal`, `gender`, `orientation`, `pronouns`, `distance_km`, `profile_completion`, `visibility`, `show_phone`, `show_distance`, `incognito`, `travel_city`, `latitude`, `longitude`, `updated_at`) VALUES
(16, 'Curious about people and places. I laugh easily and cook when I need to reset.', 'Travel, cooking, yoga', 'Live music, brunch, long walks', 'sundowners, farmer markets', 'Nairobi', 'Westlands', 'Long-term', 'Woman', 'Men', 'she/her', 50, 95, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(17, 'Product designer by day, amateur photographer on weekends.', 'Photography, hiking, tech', 'Good coffee, design podcasts', 'street photography, scifi', 'Nairobi', 'Kilimani', 'Long-term', 'Man', 'Women', 'he/him', 50, 92, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(18, 'Nurse who loves dancehall and quiet Sundays.', 'Dance, reading, fitness', 'Afrobeats, Netflix documentaries', 'thrifting, plant care', 'Nairobi', 'South B', 'Long-term', 'Woman', 'Men', 'she/her', 50, 90, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(19, 'Engineer who runs at 5am and debates football at 5pm.', 'Football, running, gaming', 'Road trips, craft beer', 'F1, barbecue', 'Kampala', 'Kololo', 'Long-term', 'Man', 'Women', 'he/him', 50, 88, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(20, 'Writer and weekend painter. I collect playlists and bad jokes.', 'Art, music, writing', 'Indie films, book clubs', 'poetry nights, ceramics', 'Kampala', 'Bugolobi', 'New friends', 'Woman', 'Everyone', 'she/her', 50, 94, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(21, 'Startup operator. I travel for work and always find the best local food.', 'Business, travel, food', 'Networking, jazz', 'wine tasting, SaaS', 'Dar es Salaam', 'Masaki', 'Short-term', 'Man', 'Women', 'he/him', 50, 85, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(22, 'Teacher who hikes on school holidays. Dog mom.', 'Hiking, pets, teaching', 'Nature walks, board games', 'rescue dogs, camping', 'Lagos', 'Lekki', 'Long-term', 'Woman', 'Men', 'she/her', 50, 91, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(23, 'Chef in the making. Hidden food spots are my love language.', 'Cooking, food, football', 'Markets, sports nights', 'grilling, spice blends', 'Lagos', 'Ikeja', 'Long-term', 'Man', 'Women', 'he/him', 50, 87, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(24, 'Fashion stylist with a soft spot for vinyl and slow mornings.', 'Fashion, music, yoga', 'Thrift hauls, beach days', 'vinyl, pilates', 'Cape Town', 'Sea Point', 'Still figuring it out', 'Woman', 'Everyone', 'she/her', 50, 93, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(25, 'Finance guy who still plays Sunday league.', 'Sports, business, reading', 'Investing podcasts, gym', 'golf, mentorship', 'London', 'Shoreditch', 'Long-term', 'Man', 'Women', 'he/him', 50, 89, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(26, 'Software developer. I build things, break them, then fix them better.', 'Technology, gaming, hiking', 'Open source, sci-fi', 'hackathons, drones', 'London', 'Brixton', 'Long-term', 'Man', 'Women', 'he/him', 50, 90, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(27, 'Lawyer who escapes to the coast whenever possible.', 'Travel, beach, reading', 'Legal thrillers, sunset drives', 'snorkeling, advocacy', 'New York', 'Brooklyn', 'Long-term', 'Woman', 'Men', 'she/her', 50, 96, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(28, 'NGO program lead. Community and good coffee in equal measure.', 'Volunteering, coffee, nature', 'Impact stories, farmers markets', 'grant writing, birding', 'New York', 'Queens', 'Long-term', 'Woman', 'Men', 'she/her', 50, 92, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(29, 'DJ on weekends, analyst on weekdays. Rhythm is life.', 'Music, dance, nightlife', 'Afrobeats sets, vinyl', 'mixing, festival travel', 'Dubai', 'Marina', 'New friends', 'Man', 'Everyone', 'he/him', 50, 86, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(30, 'Med student with a serious tea habit.', 'Reading, yoga, coffee', 'Study playlists, walks', 'anatomy sketches, matcha', 'Mumbai', 'Bandra', 'Long-term', 'Woman', 'Men', 'she/her', 50, 94, 1, 0, 1, 0, NULL, NULL, NULL, NULL),
(31, 'Platform super administrator', '', '', '', 'Nairobi', '', 'N/A', '', '', '', 50, 100, 0, 0, 1, 0, NULL, NULL, NULL, NULL);

-- --------------------------------------------------------

--
-- Table structure for table `user_prompt_answers`
--

CREATE TABLE `user_prompt_answers` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `prompt_id` int(11) DEFAULT NULL,
  `answer` varchar(500) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `user_subscriptions`
--

CREATE TABLE `user_subscriptions` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `plan_id` int(11) DEFAULT NULL,
  `status` enum('active','cancelled','expired','past_due') DEFAULT 'active',
  `starts_at` datetime DEFAULT NULL,
  `ends_at` datetime DEFAULT NULL,
  `payment_provider` varchar(50) DEFAULT NULL,
  `provider_reference` varchar(190) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `verification_requests`
--

CREATE TABLE `verification_requests` (
  `id` bigint(20) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `type` enum('photo','identity') NOT NULL,
  `status` enum('pending','approved','rejected','expired') DEFAULT 'pending',
  `reference` varchar(255) DEFAULT NULL,
  `reviewer_id` bigint(20) UNSIGNED DEFAULT NULL,
  `created_at` datetime DEFAULT current_timestamp(),
  `reviewed_at` datetime DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

-- --------------------------------------------------------

--
-- Table structure for table `visitor_events`
--

CREATE TABLE `visitor_events` (
  `id` bigint(20) UNSIGNED NOT NULL,
  `session_key` varchar(64) NOT NULL,
  `user_id` bigint(20) UNSIGNED DEFAULT NULL,
  `path` varchar(255) NOT NULL DEFAULT '/',
  `method` varchar(10) DEFAULT 'GET',
  `ip` varchar(45) DEFAULT NULL,
  `user_agent` varchar(500) DEFAULT NULL,
  `referrer` varchar(500) DEFAULT NULL,
  `country` varchar(80) DEFAULT NULL,
  `region` varchar(120) DEFAULT NULL,
  `city` varchar(120) DEFAULT NULL,
  `continent` varchar(40) DEFAULT NULL,
  `latitude` decimal(10,7) DEFAULT NULL,
  `longitude` decimal(10,7) DEFAULT NULL,
  `accuracy_m` decimal(10,2) DEFAULT NULL,
  `geo_source` enum('none','ip','gps','manual') DEFAULT 'none',
  `is_bot` tinyint(4) DEFAULT 0,
  `created_at` datetime NOT NULL DEFAULT current_timestamp()
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

--
-- Dumping data for table `visitor_events`
--

INSERT INTO `visitor_events` (`id`, `session_key`, `user_id`, `path`, `method`, `ip`, `user_agent`, `referrer`, `country`, `region`, `city`, `continent`, `latitude`, `longitude`, `accuracy_m`, `geo_source`, `is_bot`, `created_at`) VALUES
(1, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, -1.2943929, 36.7830225, 77.00, 'gps', 0, '2026-08-31 11:37:21'),
(2, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'discovery', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, -1.2943929, 36.7830225, 77.00, 'gps', 0, '2026-08-31 11:39:12'),
(3, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'matches', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/discovery', NULL, NULL, NULL, NULL, -1.2943929, 36.7830225, 77.00, 'gps', 0, '2026-08-31 11:39:13'),
(4, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'matches', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/matches', NULL, NULL, NULL, NULL, -1.2943929, 36.7830225, 77.00, 'gps', 0, '2026-08-31 11:39:15'),
(5, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'premium', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/matches', NULL, NULL, NULL, NULL, -1.2943929, 36.7830225, 77.00, 'gps', 0, '2026-08-31 11:39:16'),
(6, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'profile', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/premium', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:18'),
(7, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'profile', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/premium', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:21'),
(8, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'profile/photo', 'POST', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/profile', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:32'),
(9, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'profile', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/profile', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:32'),
(10, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'discovery', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/profile', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:50'),
(11, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'matches', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/discovery', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:51'),
(12, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/matches', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:39:53'),
(13, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/matches', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:45:04'),
(14, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'discovery', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:54:27'),
(15, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'matches', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/discovery', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 11:54:31'),
(16, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/matches', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:13:53'),
(17, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:10'),
(18, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:11'),
(19, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:11'),
(20, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:11'),
(21, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:11'),
(22, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:12'),
(23, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:12'),
(24, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:13'),
(25, 'd50c85e1c1519996de1a45611fa45e7d', 31, 'admin', 'GET', '::1', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/152.0.0.0 Safari/537.36', 'http://localhost/velora-dating-platform/public/admin', NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'none', 0, '2026-08-31 12:14:13');

--
-- Indexes for dumped tables
--

--
-- Indexes for table `admin_activity_logs`
--
ALTER TABLE `admin_activity_logs`
  ADD PRIMARY KEY (`id`),
  ADD KEY `admin_id` (`admin_id`);

--
-- Indexes for table `blocks`
--
ALTER TABLE `blocks`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `uniq_block` (`user_id`,`blocked_user_id`),
  ADD KEY `idx_blocks_blocked` (`blocked_user_id`,`user_id`);

--
-- Indexes for table `boosts`
--
ALTER TABLE `boosts`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`);

--
-- Indexes for table `chat_presence`
--
ALTER TABLE `chat_presence`
  ADD PRIMARY KEY (`user_id`,`peer_id`),
  ADD KEY `idx_presence_peer` (`peer_id`,`user_id`);

--
-- Indexes for table `credit_transactions`
--
ALTER TABLE `credit_transactions`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`);

--
-- Indexes for table `credit_wallets`
--
ALTER TABLE `credit_wallets`
  ADD PRIMARY KEY (`user_id`);

--
-- Indexes for table `events`
--
ALTER TABLE `events`
  ADD PRIMARY KEY (`id`),
  ADD KEY `organizer_user_id` (`organizer_user_id`);

--
-- Indexes for table `icebreaker_suggestions`
--
ALTER TABLE `icebreaker_suggestions`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `interests`
--
ALTER TABLE `interests`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `name` (`name`);

--
-- Indexes for table `likes`
--
ALTER TABLE `likes`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `uniq_like` (`user_id`,`target_user_id`),
  ADD KEY `idx_likes_target` (`target_user_id`,`user_id`);

--
-- Indexes for table `matches`
--
ALTER TABLE `matches`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `uniq_match` (`user_one_id`,`user_two_id`),
  ADD KEY `user_two_id` (`user_two_id`),
  ADD KEY `idx_matches_users` (`user_one_id`,`user_two_id`);

--
-- Indexes for table `messages`
--
ALTER TABLE `messages`
  ADD PRIMARY KEY (`id`),
  ADD KEY `idx_chat` (`sender_id`,`receiver_id`,`created_at`),
  ADD KEY `idx_messages_pair_id` (`sender_id`,`receiver_id`,`id`),
  ADD KEY `idx_messages_receiver_read` (`receiver_id`,`is_read`,`created_at`);

--
-- Indexes for table `notifications`
--
ALTER TABLE `notifications`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`,`is_read`);

--
-- Indexes for table `notification_preferences`
--
ALTER TABLE `notification_preferences`
  ADD PRIMARY KEY (`user_id`);

--
-- Indexes for table `passes`
--
ALTER TABLE `passes`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `uniq_pass` (`user_id`,`target_user_id`),
  ADD KEY `idx_passes_target` (`target_user_id`,`user_id`);

--
-- Indexes for table `payment_settings`
--
ALTER TABLE `payment_settings`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `payment_transactions`
--
ALTER TABLE `payment_transactions`
  ADD PRIMARY KEY (`id`),
  ADD KEY `plan_id` (`plan_id`),
  ADD KEY `idx_payments_user_created` (`user_id`,`created_at`);

--
-- Indexes for table `profile_prompts`
--
ALTER TABLE `profile_prompts`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `promo_codes`
--
ALTER TABLE `promo_codes`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `code` (`code`);

--
-- Indexes for table `reports`
--
ALTER TABLE `reports`
  ADD PRIMARY KEY (`id`),
  ADD KEY `reporter_id` (`reporter_id`),
  ADD KEY `reported_user_id` (`reported_user_id`),
  ADD KEY `status` (`status`),
  ADD KEY `idx_reports_status_created` (`status`,`created_at`);

--
-- Indexes for table `sessions`
--
ALTER TABLE `sessions`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`);

--
-- Indexes for table `subscription_plans`
--
ALTER TABLE `subscription_plans`
  ADD PRIMARY KEY (`id`);

--
-- Indexes for table `super_likes`
--
ALTER TABLE `super_likes`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`),
  ADD KEY `target_user_id` (`target_user_id`);

--
-- Indexes for table `users`
--
ALTER TABLE `users`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `email` (`email`),
  ADD KEY `status` (`status`),
  ADD KEY `role` (`role`),
  ADD KEY `idx_users_status_seen` (`status`,`last_seen_at`),
  ADD KEY `idx_users_dob` (`dob`);

--
-- Indexes for table `user_interests`
--
ALTER TABLE `user_interests`
  ADD PRIMARY KEY (`user_id`,`interest_id`),
  ADD KEY `idx_user_interests_interest` (`interest_id`,`user_id`);

--
-- Indexes for table `user_photos`
--
ALTER TABLE `user_photos`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`),
  ADD KEY `idx_photos_user_mod` (`user_id`,`moderation_status`,`is_primary`);

--
-- Indexes for table `user_preferences`
--
ALTER TABLE `user_preferences`
  ADD PRIMARY KEY (`user_id`);

--
-- Indexes for table `user_profiles`
--
ALTER TABLE `user_profiles`
  ADD PRIMARY KEY (`user_id`),
  ADD KEY `idx_profiles_visibility_completion` (`visibility`,`profile_completion`),
  ADD KEY `idx_profiles_city` (`city`);

--
-- Indexes for table `user_prompt_answers`
--
ALTER TABLE `user_prompt_answers`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `uq_answer` (`user_id`,`prompt_id`),
  ADD KEY `prompt_id` (`prompt_id`);

--
-- Indexes for table `user_subscriptions`
--
ALTER TABLE `user_subscriptions`
  ADD PRIMARY KEY (`id`),
  ADD KEY `plan_id` (`plan_id`),
  ADD KEY `user_id` (`user_id`,`status`),
  ADD KEY `idx_subs_user_status_ends` (`user_id`,`status`,`ends_at`);

--
-- Indexes for table `verification_requests`
--
ALTER TABLE `verification_requests`
  ADD PRIMARY KEY (`id`),
  ADD KEY `user_id` (`user_id`),
  ADD KEY `reviewer_id` (`reviewer_id`);

--
-- Indexes for table `visitor_events`
--
ALTER TABLE `visitor_events`
  ADD PRIMARY KEY (`id`),
  ADD KEY `idx_visitor_session` (`session_key`),
  ADD KEY `idx_visitor_created` (`created_at`),
  ADD KEY `idx_visitor_user` (`user_id`),
  ADD KEY `idx_visitor_country` (`country`),
  ADD KEY `idx_visitor_path` (`path`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `admin_activity_logs`
--
ALTER TABLE `admin_activity_logs`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

--
-- AUTO_INCREMENT for table `blocks`
--
ALTER TABLE `blocks`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `boosts`
--
ALTER TABLE `boosts`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `credit_transactions`
--
ALTER TABLE `credit_transactions`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `events`
--
ALTER TABLE `events`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `icebreaker_suggestions`
--
ALTER TABLE `icebreaker_suggestions`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;

--
-- AUTO_INCREMENT for table `interests`
--
ALTER TABLE `interests`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=64;

--
-- AUTO_INCREMENT for table `likes`
--
ALTER TABLE `likes`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

--
-- AUTO_INCREMENT for table `matches`
--
ALTER TABLE `matches`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `messages`
--
ALTER TABLE `messages`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `notifications`
--
ALTER TABLE `notifications`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT for table `passes`
--
ALTER TABLE `passes`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
-- AUTO_INCREMENT for table `payment_transactions`
--
ALTER TABLE `payment_transactions`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

--
-- AUTO_INCREMENT for table `profile_prompts`
--
ALTER TABLE `profile_prompts`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `promo_codes`
--
ALTER TABLE `promo_codes`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `reports`
--
ALTER TABLE `reports`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `sessions`
--
ALTER TABLE `sessions`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT for table `subscription_plans`
--
ALTER TABLE `subscription_plans`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;

--
-- AUTO_INCREMENT for table `super_likes`
--
ALTER TABLE `super_likes`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `users`
--
ALTER TABLE `users`
  MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=47;

--
-- AUTO_INCREMENT for table `user_photos`
--
ALTER TABLE `user_photos`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=182;

--
-- AUTO_INCREMENT for table `user_prompt_answers`
--
ALTER TABLE `user_prompt_answers`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `user_subscriptions`
--
ALTER TABLE `user_subscriptions`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;

--
-- AUTO_INCREMENT for table `verification_requests`
--
ALTER TABLE `verification_requests`
  MODIFY `id` bigint(20) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT for table `visitor_events`
--
ALTER TABLE `visitor_events`
  MODIFY `id` bigint(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=26;

--
-- Constraints for dumped tables
--

--
-- Constraints for table `admin_activity_logs`
--
ALTER TABLE `admin_activity_logs`
  ADD CONSTRAINT `admin_activity_logs_ibfk_1` FOREIGN KEY (`admin_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `blocks`
--
ALTER TABLE `blocks`
  ADD CONSTRAINT `blocks_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `blocks_ibfk_2` FOREIGN KEY (`blocked_user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `boosts`
--
ALTER TABLE `boosts`
  ADD CONSTRAINT `boosts_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `chat_presence`
--
ALTER TABLE `chat_presence`
  ADD CONSTRAINT `chat_presence_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `chat_presence_ibfk_2` FOREIGN KEY (`peer_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `credit_transactions`
--
ALTER TABLE `credit_transactions`
  ADD CONSTRAINT `credit_transactions_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `credit_wallets`
--
ALTER TABLE `credit_wallets`
  ADD CONSTRAINT `credit_wallets_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `events`
--
ALTER TABLE `events`
  ADD CONSTRAINT `events_ibfk_1` FOREIGN KEY (`organizer_user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `likes`
--
ALTER TABLE `likes`
  ADD CONSTRAINT `likes_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `likes_ibfk_2` FOREIGN KEY (`target_user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `matches`
--
ALTER TABLE `matches`
  ADD CONSTRAINT `matches_ibfk_1` FOREIGN KEY (`user_one_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `matches_ibfk_2` FOREIGN KEY (`user_two_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `messages`
--
ALTER TABLE `messages`
  ADD CONSTRAINT `messages_ibfk_1` FOREIGN KEY (`sender_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `messages_ibfk_2` FOREIGN KEY (`receiver_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `notifications`
--
ALTER TABLE `notifications`
  ADD CONSTRAINT `notifications_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `notification_preferences`
--
ALTER TABLE `notification_preferences`
  ADD CONSTRAINT `notification_preferences_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `passes`
--
ALTER TABLE `passes`
  ADD CONSTRAINT `passes_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `passes_ibfk_2` FOREIGN KEY (`target_user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `payment_transactions`
--
ALTER TABLE `payment_transactions`
  ADD CONSTRAINT `payment_transactions_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`),
  ADD CONSTRAINT `payment_transactions_ibfk_2` FOREIGN KEY (`plan_id`) REFERENCES `subscription_plans` (`id`);

--
-- Constraints for table `reports`
--
ALTER TABLE `reports`
  ADD CONSTRAINT `reports_ibfk_1` FOREIGN KEY (`reporter_id`) REFERENCES `users` (`id`),
  ADD CONSTRAINT `reports_ibfk_2` FOREIGN KEY (`reported_user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `sessions`
--
ALTER TABLE `sessions`
  ADD CONSTRAINT `sessions_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `super_likes`
--
ALTER TABLE `super_likes`
  ADD CONSTRAINT `super_likes_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`),
  ADD CONSTRAINT `super_likes_ibfk_2` FOREIGN KEY (`target_user_id`) REFERENCES `users` (`id`);

--
-- Constraints for table `user_interests`
--
ALTER TABLE `user_interests`
  ADD CONSTRAINT `user_interests_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `user_interests_ibfk_2` FOREIGN KEY (`interest_id`) REFERENCES `interests` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `user_photos`
--
ALTER TABLE `user_photos`
  ADD CONSTRAINT `user_photos_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `user_preferences`
--
ALTER TABLE `user_preferences`
  ADD CONSTRAINT `user_preferences_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `user_profiles`
--
ALTER TABLE `user_profiles`
  ADD CONSTRAINT `user_profiles_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `user_prompt_answers`
--
ALTER TABLE `user_prompt_answers`
  ADD CONSTRAINT `user_prompt_answers_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `user_prompt_answers_ibfk_2` FOREIGN KEY (`prompt_id`) REFERENCES `profile_prompts` (`id`) ON DELETE CASCADE;

--
-- Constraints for table `user_subscriptions`
--
ALTER TABLE `user_subscriptions`
  ADD CONSTRAINT `user_subscriptions_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`),
  ADD CONSTRAINT `user_subscriptions_ibfk_2` FOREIGN KEY (`plan_id`) REFERENCES `subscription_plans` (`id`);

--
-- Constraints for table `verification_requests`
--
ALTER TABLE `verification_requests`
  ADD CONSTRAINT `verification_requests_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`),
  ADD CONSTRAINT `verification_requests_ibfk_2` FOREIGN KEY (`reviewer_id`) REFERENCES `users` (`id`);
COMMIT;

/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
