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


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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$ysAuVos3nH3l3y9gNWj6xfflHqEICHmKjSlZ2usl4N0jPcuuDDv6p','admin','ak_3f6048229f9e0624','2023-07-27 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$IK6tFMzqQh.Bm6NPMDwPBb8El3fyOm4AvnDsZ2Q78LKIScMfUjowE','user','ak_f6e646c08b0dd88f','2023-07-01 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$s1xKQ6r6jDMNt6pP4hwRLuSVug3Koocxbptre74/wIFoOSA5ST5H8','user','ak_32a1fe563fee6ad5','2023-02-21 10:05:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@example.org','$2b$12$.I53BPTtwAeT9Bfq5BuRFL/pHp2jwnNajp0.OFC/NNqlGKJZ71U.4','admin','ak_c95ceaec071ca6cb','2023-04-19 10:18:00',NULL);
INSERT INTO `users` VALUES (5,'root@example.org','$2b$12$hwy/Aw6eH5wYZYGaXDFHtLAJ2txq3Cq2/dB8IJy40Mr8sdm9E7xOZ','admin','ak_a58aedf69414d38f','2023-10-23 10:03:00',NULL);

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

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


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

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


