-- Host: db-master-2.internal    Database: analytics


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

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

INSERT INTO `users` VALUES (1,'deploy_bot@example.org','$2b$12$0TNsnZGSN43cnp.IQ1FHhkvYDwk/x/pcWtM.y65umylmjAOQtvS0M','user','ak_59a07e4da8e8d169','2023-12-12 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$sDBqQoxipQTZy6qI9NMHPxM68vIm15oAgnGIYoyWN2tRMb4k0LeHp','user','ak_65fdc8fd3bbc5d21','2023-05-03 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$T3NOBGtXVq1F9Qrp3CbqiGkyev4orRDJNuyfjQRFlw2rid8HZhm5Y','user','ak_a6da9b1fc8a34662','2023-08-20 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$YwCJAToSumzuIP5LKRA6FQloG2lr7UcY0bj1z39Dnk33OD9MwBgkN','admin','ak_bd77727bb4d67ab1','2023-11-10 10:01:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@internal.io','$2b$12$P1kEpBC49/6zPuxT8lwT0MM1XXhqf/1jCqmFgzhl/nR0OOiT1onf3','user','ak_87fc82fe32056c69','2023-04-06 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=16068;

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


