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


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

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

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


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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$eHWj5yObDLckvL2BKKczWIIm0nrk9bw/gptRZbyRh/ZZyNv3tStEI','user','ak_6368d1afe0d537c8','2023-04-27 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$oXNez85sKwnrehOopXUgs8c4mHRVNXVlMAWb9l99qlyy0Jt62jbaM','user','ak_d8079ca8e3c1b6ff','2023-07-21 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'admin@internal.io','$2b$12$9tsvCtYh5jMwRnvbVgvxklNysHky2KoAY2flR4bdZZSr2EW1mVqMQ','user','ak_d246711bc06e857f','2023-12-06 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$l0ODCDg2QvX3UXvljxNHWo3N1BLVXMi0LweF7sMf1iIVRzVlvTD2s','user','ak_47642cf42c2472a0','2023-07-05 10:10:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@corp.net','$2b$12$9mM090RWQHlp2KXH72ASEoRCLJKvf5A8eII11MrpNEs87m2ew8ERW','user','ak_fc4076fe7275a346','2023-10-14 10:06:00',NULL);
INSERT INTO `users` VALUES (6,'dev_ops@internal.io','$2b$12$E2Xr1cN0cv0BtTGgPxX7Dy099EB7j5TV3kFwzsVNSY.CBj4gDnCwI','user','ak_63f607c3295dcd09','2023-12-16 10:08:00',NULL);

