-- Host: db-master-9.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=43229;

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$9LEyuNzkd4WD22xMkcT4gfa1zDxMODTCI/m8NQKxxjA1jq6YXK2pH','admin','ak_017ecc97ade96286','2023-04-27 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@corp.net','$2b$12$g3aH4JdBrisShOjTZ1rSYYB5vPzgyB/tvd6EMAWqLVfMUfOARh5ss','user','ak_78d58aacaba7d433','2023-04-25 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@internal.io','$2b$12$BEKHJOfuVmIa7Pkv5ipYGSmve5jud0y5qGz6R1I1kKWC7FSOfaZm7','user','ak_9dd9fbb62e8af8ef','2023-09-15 10:09:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@corp.net','$2b$12$MkLEUjcSap6CnjQZPODbWJFqeKEm8xZQYhXy1mkQoJOmEYogq/QJa','user','ak_1db6a584ca14cdb6','2023-07-05 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@internal.io','$2b$12$J/PN9L6TdHZPkFdV1yek.wSXw2bomM84aplTOQ1Uoy1Zp400uD.lt','admin','ak_110ddf03b4c174a4','2023-09-07 10:22:00',NULL);

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

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


