-- Host: db-master-8.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=2405;

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

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$do4kFaGo54V/6jxu41XrGj/Oujwa.F0nrhYZYwm7EfQRoPCGtsQDJ','admin','ak_a292ccb489f4387b','2023-12-14 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$n6MeB9.xghkXhF6o68v7hGnQnASeahhfOQkBfo4iYdp7YPTfbv2QC','user','ak_438830c3be3555c6','2023-07-28 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@internal.io','$2b$12$J5VAhMXHtBfq6X88x2gqbQ4i54pOnjQfMJgIEQ9XRb1IVzS2LU8Hk','admin','ak_f54ceb9b8b884d67','2023-04-25 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$pPFxDNjVLD7VMdayzI6H91j4.vir3fcrW0KLV7J0TTG8mVrJwUgfl','admin','ak_4ffb5ac1d02a6f76','2023-04-22 10:13:00',NULL);
INSERT INTO `users` VALUES (5,'root@example.org','$2b$12$/q8qBO5Mj.qW6Ds.qnh9HoH.yggN8jMePlPAuAkJwOi36aWRJKtDk','user','ak_d3eaa884dcd7482c','2023-03-16 10:11:00',NULL);

