-- Host: db-master-5.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=16507;

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$o7vmL4kWVBYINzNS4ZX9kNh6THhMHJOwE9tYo1UItTpA2ZDz0ThwS','user','ak_a13a8e77b13290b6','2023-04-07 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$c9m977Eeqypofv/tsfjveQo1lD44LC8EdMTkF6v1yoTL7wnHiLrFP','admin','ak_5165da47062740b4','2023-08-28 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$oGz5s/IxKPbixPkNdVlrHcD99KlWEsIc1fF7QXJvfHIdmeTXmzLoc','user','ak_4d11cb77be1a0e29','2023-05-20 10:03:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@example.org','$2b$12$j8Ts4i8qYrjaBOKbLUfL.0HFNNXZicKUVRbx3NJ/Yn4wASuC5B2l1','user','ak_7e13d57e67134cec','2023-07-17 10:13: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=23192;

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


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

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


