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


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=8974;

--
-- Dumping data for table `products`
--


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

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

INSERT INTO `users` VALUES (1,'john.doe@example.org','$2b$12$JSp0yUI/lM7tl0aOJL3rQsuUia98Ag83LDhY..YUv/PYjYuLR6ka5','admin','ak_57bf80e54bc3ae13','2023-09-17 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$AgLghYKpMiKENaZCu5PTnI8oWY/F3iBbFFWW4szt41KOTLeAwbGmW','user','ak_719de71d9acb1b01','2023-04-15 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$8v.SxdeA6FrOAvhroMlTOvFZJJ7xJaX3oTbYU12/M8EFd6SLxCUBo','admin','ak_a397d27a537c71c8','2023-04-25 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@internal.io','$2b$12$lRusSic8g5uowFJNmMxouUFQXyzKYAybFvGdHoSzGAw4OVXyQDSds','user','ak_cb981f92857c27dc','2023-07-24 10:05:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@internal.io','$2b$12$24ZWKk2GwE0/c2J4cj9eV40kBlHkqF.JamZJdA8UXpwQz3wj7/D1A','admin','ak_4f8453f23c871438','2023-12-16 10:01: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=4859;

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


