-- Host: db-master-0.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=6035;

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

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

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

INSERT INTO `users` VALUES (1,'dev_ops@corp.net','$2b$12$GwLd93tXnbQGupxkndwvLJjMCX6kK6DpcBS5.3q4Hia1YJEtfZXKr','admin','ak_eb0f3a25e48f9d88','2023-08-15 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$sbps7UXVw8WsRm3L9Vwyam7hRaUD0KydIlIbRavqi0GIAIQg/DHCd','user','ak_14f3d7c0c234cf4c','2023-06-22 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$0KWqHMQ2tbEUrV0sWGXUubrwfDmxgJ1720XdERMoZdFHc/Il9DRse','admin','ak_d5f0e1d753a421b5','2023-05-21 10:10:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$Ud8KJ2FigxpcuQAklLj0s9brNsdPDBcGtHG/P9nz54BmJmDmHOawu','user','ak_3e8350289cf4c52c','2023-10-06 10:06:00',NULL);

