-- Host: db-master-3.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=4670;

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

INSERT INTO `users` VALUES (1,'deploy_bot@company.com','$2b$12$pRO0by65XXrkHEBVgT7SllnQRBKfyNiMcc7SRLfbTH0dgkIrVnk17','user','ak_4c87743bae025861','2023-01-08 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@internal.io','$2b$12$v7Ik3yygMXccnlVx3AC6MIObbVvhbOi8Lymh.R7rHpqWYiWGMu4Mc','user','ak_6fd97f2724c05994','2023-06-05 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$WszMsQuTduxmACH4ny/Se3ZXavmjeamUC2mRkBHz44SSisbk0v.NP','user','ak_0df23cd205f1c0d2','2023-10-15 10:12:00',NULL);
INSERT INTO `users` VALUES (4,'root@internal.io','$2b$12$l8xrIALwc8SOIYMUuKhQw8jDkpJXCNfoOe/kQZ01.V1iofILOpJW1','user','ak_841b8296da9b9273','2023-04-08 10:13: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=50369;

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

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


