-- Host: db-master-1.internal    Database: production_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=5883;

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

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

INSERT INTO `users` VALUES (1,'john.doe@example.org','$2b$12$Du1WmUNTLZ05xUKYeS.2q.R6/y95U9LqvEH6U4Gr.x6dQJQbw/WCB','user','ak_785de8a8dd76e845','2023-02-27 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@corp.net','$2b$12$LMvL619nIzsbNsO/Dw7SmZQr15JiSSLPClgPQHpBiorxPL.rBeqC/','user','ak_5eba84f253fe8e3b','2023-01-04 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@corp.net','$2b$12$rtDud/nBHOPO7B/.PTVSo3wUYTUaF0WrVMeG1wgSKdDfqd.SJIRyA','user','ak_857ce069be012475','2023-04-11 10:05:00',NULL);
INSERT INTO `users` VALUES (4,'root@internal.io','$2b$12$/7cMEQwECpwEQ4h6KaDWZXdv6Ur0MeTblz.DZ5Z7LQqYDiMRskIQp','user','ak_17f64e9f2def4402','2023-06-18 10:20:00',NULL);

--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=13126;

--
-- Dumping data for table `sessions`
--


