-- Host: db-master-6.internal    Database: ecommerce


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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$cbgL21I4VUG92MqMlfjPH8Cqg6yNXfgHYXSi4aboqrks2oa5SjpaQ','user','ak_9390a4546015045f','2023-12-19 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$s8z8igH8yCK7sN5I7y.HAUlyUaDqstBvwqkhb9GOybRq.9QzA05jM','user','ak_69787026b150cfa3','2023-06-08 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@internal.io','$2b$12$Pa/DARyNKBRtKXC0XPQEeZt2QHD1ITAycwUI9pP.ADdeIywjCmEV7','admin','ak_4ee5757311672a1c','2023-07-28 10:14:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$O0/szGn58vVSazF4LcN7bFwX7gskE5eg7bteK3Fx0brCCpvPJol7h','admin','ak_7ee739cf13beefeb','2023-12-15 10:16:00',NULL);
INSERT INTO `users` VALUES (5,'root@internal.io','$2b$12$x/kbLD6Qk.A3KPA6nk4UYsYPlBbcSZNj2KbTczTvqyXScZQZ7mrJL','user','ak_f11343f4563e9e23','2023-07-28 10:11: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=10298;

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


