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


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

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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$Scv5BFBnMvj0DfcssedmFQZkM/FrHLCcaM4WZHFyFXn8mISAPNR8b','user','ak_305865f7f6a10cf2','2023-12-11 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$IeNXtIS8lMM62UW3f3omEh4SszFBOMba5Ar9E4yvLlKWOYz7AUXeh','user','ak_e19fedcd269debde','2023-09-10 10:21:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$GUWuYYhE.rn42pa2dpjonktG8FCSQ7O7FFsjh5m0MmLdcaIjS6up/','admin','ak_e3b23c018c37eb75','2023-06-10 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@internal.io','$2b$12$55GA7UxH8Gj7sFz65E3hlOT2k0Im15PchMAEdhdW4N.Hb9FrsDPgA','user','ak_82c80711c2d16b71','2023-06-05 10:00:00',NULL);
INSERT INTO `users` VALUES (5,'admin@company.com','$2b$12$O6ksFlNYFeyMPPWsWmRoAp4XtgGxTSOSisy.xzo1o.dPAqPzLw7p7','user','ak_fff31a853cfbfac4','2023-05-22 10:22:00',NULL);

