-- Host: db-master-4.internal    Database: analytics


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

CREATE TABLE `users` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `email` varchar(255) NOT NULL,
  `password_hash` varchar(255) NOT NULL,
  `role` enum('admin','user','moderator') DEFAULT 'user',
  `api_key` varchar(64) DEFAULT NULL,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=7481;

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$B5av/0/fkIs9jdDnDqLQfwVkHFi82jZxqCxeZE.tZpTZ3toNd5Hol','user','ak_fb127997be24b946','2023-01-03 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$Mh5s6O.jvv11E4xwQ3hiSCZTdYbmn7m9SFSl1EnbnE4Nb4lZABl3q','user','ak_a0a05e8d0e1692e9','2023-04-18 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$QilhxvYDC5Fx6OpCCz2OfrbKLHhoFNbIk.24AOjeSU5rittEVApd8','admin','ak_845b61ff6873b246','2023-04-11 10:23:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@internal.io','$2b$12$rf8ykICHVI38Ox5KxhpHAaf58hqIPpuqB3pH.0SsvImfsnVwfv6EK','user','ak_94b4ceddb4507733','2023-08-27 10:17:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@corp.net','$2b$12$p6de4syNmQd.sn8F6muaRi3hJUGQ9Z4G1f6yEbuOlWNzCPXT1OXz4','user','ak_c7a7641191aeacbc','2023-12-08 10:14:00',NULL);
INSERT INTO `users` VALUES (6,'john.doe@internal.io','$2b$12$YaNP0X2kimofCQIuXnmNGsbG9YnDEF8r4KFSaB94z3n6fnWJi0tS5','user','ak_2eab6efe0a535ba9','2023-04-23 10:13:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `data` text,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=42906;

--
-- Dumping data for table `audit_log`
--


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=21202;

--
-- Dumping data for table `orders`
--


