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

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

INSERT INTO `users` VALUES (1,'dev_ops@internal.io','$2b$12$m/.pA55h8d/TGRtZqIVo..VOBr2orcDJHYzYOE3qKn5/ryuLwDePG','user','ak_6853f99b08602f59','2023-05-22 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$NZwUIQgVB/H53X7gaR6nTtKq8qhWeYr31bxs7F7ukpk8dT1cNFQFA','user','ak_a5bc877ab6b4dd3a','2023-10-03 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$tNoQVkIyxMPEnCAsI3NL0LEfsD92W4to8BEcvzgbtNI6XiVz7AFow','user','ak_283ca69e8956aed7','2023-03-22 10:09:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@example.org','$2b$12$BrRwxsn74ZQIgvGwmOD981yn.4rLUug5YQItoS0/ayOO9NZIsMO/W','user','ak_c36c8a71d64350e8','2023-07-19 10:08:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@corp.net','$2b$12$CMFyG0Pz5fowmlnwwDayNwkMHXabjQFtp5xqWlJVMUbeFjUyzDiUQ','user','ak_0e8ad0df83a802bd','2023-10-04 10:00: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=11326;

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


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

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


