-- Host: db-master-3.internal    Database: main_app


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$jVoHxA0qMPq0MeeuBTXXPa0bsPGA7CiikACdLNXcumcOMr5O7svWK','admin','ak_8264cd3265fd9dec','2023-10-15 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$Up/l3TnuX0n9MSLmjTsMkHpEhfFZRFopzO6enKdZ9qmlt3x2QRCI6','user','ak_5cbd84789f1af56e','2023-10-02 10:21:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$1Du2MIbOYHXNUpFPKLykl0t7tX8Pjj75Ysz79tkNXtE/IQ5L3Xszy','admin','ak_256b9a289526c3d9','2023-03-13 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$J/xktFI8EVfdCECaxdTbLJF4m.grkGcilcNgizkwNO3C68r/l5TnG','admin','ak_54cb49a51901c4ff','2023-09-06 10:23:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@company.com','$2b$12$F3vAv/DCN4WY6IuHBAQoE55zpmF0LqvnJmG/6kifouqG9qBe3Z5DE','admin','ak_8f2c797506a329e6','2023-03-09 10:19:00',NULL);
INSERT INTO `users` VALUES (6,'service_account@internal.io','$2b$12$WVA7VCiw.OgWjR29F5gY4MKiAhwg3xSonoOdr1whQYXO6s/zhTI2s','user','ak_7685fd475dd5ef38','2023-06-05 10:19:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=12148;

--
-- Dumping data for table `audit_log`
--


