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


--
-- 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=16501;

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


--
-- 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=14981;

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$s1d2UiNHYTJSGuCXKi7rP28s/3QC8vIgxNTazpJOLga9jDmJ9gtOV','user','ak_37295f0f4fd3cc2b','2023-09-15 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$azuVJIWpQW7MTJPFR/L4E.aKphja9l/P2kBx19UNKKtJ4cU.1.HmP','user','ak_5d849c38b8b67ce6','2023-01-23 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@internal.io','$2b$12$r0ovnybqQ9S6ju68qtATnQAZjf2mkl/bt75paaIaRl/7bCQds2SB7','admin','ak_0c87dd92f51ca8a1','2023-09-06 10:14:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@internal.io','$2b$12$D0prB9WdUfTmLL/IQNt/hpYgZIgTT4EJrkCptstLzKoUbnAb.x/ON','user','ak_6ef003523f2b6460','2023-07-03 10:22:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@example.org','$2b$12$yZFQzhP1waRUp7WAiUbcQWy5BmmiAyK.xO/AgqJ7PLb/QuZ4JBA9s','admin','ak_c1a3a8a8559d9096','2023-04-05 10:13:00',NULL);
INSERT INTO `users` VALUES (6,'backup_admin@example.org','$2b$12$S8tEa7mrI4grU9dPsQ54WInRGv2D.rwadVIil4bceLvvrZBqc0/bV','user','ak_fc31bcd0e6465e65','2023-07-03 10:21:00',NULL);

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

CREATE TABLE `sessions` (
  `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=12906;

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


