-- Host: db-master-2.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=17399;

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

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$cCAlvFsv/wo6/UdpRvZluvI2X4mtaPNo4o7PGrUPf/IiUgJkVihgg','admin','ak_30c5b3c223076a15','2023-05-04 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$5GuLSShIzmUWXj7ImvsPz1KI6JugHTC.4dM9zGWMuce1KZPkvRg17','user','ak_3b0db745fa3704b5','2023-10-06 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$fxmEJw9dob0gYg/vS1L2Ux.kkPdJl7TtODw8.iX8pwtlaTwNGBPLs','admin','ak_2e44017e3919268f','2023-05-05 10:14:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$Qpbkq5h9N2R9StqoI7u.Qw.mS9x0cL8yaaIAgZ2OKLpvFVBZFauGg','user','ak_dc64b83b91aca035','2023-05-12 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@company.com','$2b$12$GJLJ88yUjs1zDIiClvBsyIr7YtZmLCte3pYItm1RKrWoCY0Z2e8XZ','user','ak_2aa172d141f27a03','2023-04-25 10:13:00',NULL);
INSERT INTO `users` VALUES (6,'service_account@company.com','$2b$12$w8rSpQ52EGSrDx2P8UKKCanHMoMGuCJnSCnzQCFxVFZjtl19pkpQ/','user','ak_5a2ad9cfb36bb2b6','2023-03-11 10:13:00',NULL);

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=22874;

--
-- Dumping data for table `sessions`
--


