-- Host: db-master-8.internal    Database: customers


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

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


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$7EO71ZkGaIZhkj.b7Oua74olYBX2HAYm1bxtEyQdqJOBJsOOfISGI','admin','ak_78af9e353824775a','2023-04-11 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@example.org','$2b$12$2fClLXPPnxORipxg4dcGHceusMAwyPkGJyvAMxBri4XKi0EzJSvFw','admin','ak_1a6347743d110685','2023-04-07 10:08:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$/xDdhoB6MTcZIVQ8M.5KbVIG4hlotMKiNXlZpPHvYTljJBU/VZe1t','user','ak_2842137d60acb4d3','2023-04-20 10:14:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$dUOWw8SP7KB.e/OIGr14o1KxKoD89B1umu/ycfr5mDd8No/wX7p7J','admin','ak_aefc57b26a97b52e','2023-05-23 10:08:00',NULL);

