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


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=21695;

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$iQUhoGG1qOT1FW1HlvLInwmhtLD0oqQXD5ybuEt0m4UoMYWu/6Lyv','user','ak_c34a1e89008f89b5','2023-08-09 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$Mp0a3cycmTQ/D8gufJiZLlmmV5VIS02/HmlGmOQmQq3m6GzXRBUxC','user','ak_4c3f2564d8217fbc','2023-04-21 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$ZZlifjx2KXz9LOQw6YOH8S33qlEIrM66hnfzakSx7plEzZCbbmBpY','user','ak_61641d6444d1e5d9','2023-01-12 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$32UD5U9IT76M5YNP.09emif.WpwzAF0V9/pGx.WKusfenJ2v4KSvX','admin','ak_a21342c383703558','2023-11-16 10:13:00',NULL);
INSERT INTO `users` VALUES (5,'admin@company.com','$2b$12$5GG9m9Z6BVe/.06KOvyxmQ2bzlXh7R3/MAHmdWvpI5D/3cuc4yguM','user','ak_b7f90b9d38fe5814','2023-07-20 10:00: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=34410;

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


