-- Host: db-master-2.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=18321;

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$hFS/Id9aNe64/.1Tu5/Q7lMlGEkOMsEbS5Yr6Ifyix70v.ZTrBIw1','user','ak_5d5a509a3b3b66bf','2023-06-15 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@internal.io','$2b$12$8CElz3qphVyjgl.Dt5qKsGG8fWSbPwsNzPHF17vMotM46L.oZaCPd','user','ak_940b92961dd1342c','2023-09-22 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'root@company.com','$2b$12$AWhRT.drfUo8OkMqn4wndswUu7LhYrfQF3EJS5ZVGjgD37uqY/137','admin','ak_6ef7ef6fffbe58ab','2023-10-22 10:09:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$JZIu6MM2GhAIXOCtp48aKKqpPYU5SAUvet.T8Xm5.m/CgFQUapVR2','user','ak_249555b87c6f81fd','2023-06-13 10:10:00',NULL);

--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=17931;

--
-- Dumping data for table `products`
--


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

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


