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


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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$36Nea7/Oj/PUFDEedbylp59tTCgviz2N51MIZj.lqnZGWYbP4iDK8','admin','ak_7541c32ecf9ae0cd','2023-06-09 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@company.com','$2b$12$AaIp1ThoaB3cMTpqwvsCwh5y0jDMVUkWnRnvk4xGMwM.jrUGtqbLb','user','ak_eee262cc98f90ad7','2023-07-28 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@example.org','$2b$12$yILLjd7b8kI5ADf71LkiG0oIYtX6gJ/dnQ0be.If8FiyWXztjYFfJ','admin','ak_6c1249ca4d0af06a','2023-03-11 10:18: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=28068;

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

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


