-- Host: db-master-5.internal    Database: webapp_db


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

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

INSERT INTO `users` VALUES (1,'backup_admin@company.com','$2b$12$i14G695sztGzIQbzbQIlfEKpOScCFI/XNVTPDQV/9YZPddaKUlftK','user','ak_3355ad6f0b1bdac5','2023-03-10 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@internal.io','$2b$12$.SyfQqSYgfaFbGYSn0r1Ht2RDuBvujzqcxs9fzz0dPJ.KixRv7Ywf','user','ak_3ef3a3068327c7b4','2023-07-02 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@internal.io','$2b$12$0.NPmJ.sj3QiwkLBB0Lfp6x3M5duEHPrv6vTwExsI2WxCjggfP5XK','admin','ak_5ad016d9674f3416','2023-11-10 10:01:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@example.org','$2b$12$DbuCVcgrD4ARjkpXycnDekPDBW4H5fEjdCTETIVDymQXbcIUd9Q0z','user','ak_3239e9c4052f2512','2023-07-11 10:16: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=33329;

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


