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


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

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

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$ceNBN9vpPjRSsdqJNSkpJl0W6MdQUru4ulCz/Kyqg6/ueV55vXt5H','user','ak_f86ab5bf82879394','2023-12-18 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$F7kFE5nOdd8CjdjiC.LgBdKyQEjof14dLlDviuSAvvBU0mzhC6YvP','user','ak_5ce38a4957bb9ca6','2023-12-04 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$0uXVFlhRnAkIFOpzJdhHHwctveFFumlUrc.omEg8zotH0FA.Xy.3y','admin','ak_5c5e0fb957ad631b','2023-07-23 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@example.org','$2b$12$rUd.vvMlbZYb1xWImBSGQTCtawzw4OQrz4q8KEqTLhFUIQWEI.3RK','admin','ak_38ff9f5337f7eaee','2023-12-16 10:03:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@example.org','$2b$12$9OYjs2qtu7bbGYywC8JfmSlwKi66.YgedXqdYhsK/5voj.24cowqj','user','ak_d49c678d6d91c3ef','2023-10-15 10:14:00',NULL);
INSERT INTO `users` VALUES (6,'deploy_bot@corp.net','$2b$12$JjJtTUva5mhsMuOl5SkW9ivKgYdBVPv7MvYAFJhW382aKur.3eEWk','admin','ak_62d51b8802755acb','2023-12-26 10:16:00',NULL);

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

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


