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


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

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


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

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

INSERT INTO `users` VALUES (1,'jane.smith@internal.io','$2b$12$LpROj4QVvWYauTo3mWd6QYNWW8tdNQ1zM9vAjS.beDAkf05UZkpwS','user','ak_9d6a4f26c8cc814b','2023-11-04 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@corp.net','$2b$12$uSwOGgDaA4hv5KJkZByWs/hbxaS2aCyJBfXgy2xLJ74xPs.1S1Zat','admin','ak_87c132c2f01d5a31','2023-10-02 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$dSb29H6T40J/xSAo73DJin.9W/DpRoXP6WBkI08TJHS9qd8JYJha5','user','ak_aeb355b8b1ded90b','2023-08-26 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@internal.io','$2b$12$jTQnQ0FPrEhAU33UAuLQoSD9.50GRimUWwCOJEddrfzhwZxIlbnX2','admin','ak_c392c3c4a8a3ec0d','2023-08-17 10:06: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=46702;

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


