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


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

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


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

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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$cYTqmwnhjYaEDD7k.gVpE/AqniHNmmZ0xnAn91EtvjDnqmFNHPIDK','user','ak_fd71be8dd4893875','2023-01-14 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$KolC8lr.wZRpf2Tc9ngyNTOqMU4DzguS2ALbqJV.0KWa/iF9EQa3m','user','ak_44b2f9584534b29a','2023-10-09 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$jNETgcHooBLhQlRTpKtF8iDkt4/J7iTSGVv0T7cO17S3..TwHLy3P','admin','ak_df9a7016cc959553','2023-11-08 10:06:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@example.org','$2b$12$pEXL4LAE40TuaZ6R25nfhiXP5UyCHMVjWHY7fe1ZhJKlnL6tc7JZR','user','ak_d9d20d236347c690','2023-11-16 10:09:00',NULL);

