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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$VZi6FtuYcZmq8EB55p7qDi6jfwnwIWP1Y7mhXPHabeCSHc5xXTe3T','admin','ak_170867d9ffb19969','2023-03-24 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$02hqba34eiD7Csg.shGMsXLaCIAkxfnyAamsHWM05H9GljbTH.9JS','user','ak_1155239129955137','2023-05-19 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$GtLdPBRweeTXzKPqd88xrbUvzesgj4gn2igURtOEyF25WPBn2Nykx','admin','ak_b9e9f1b1e70ba129','2023-11-25 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$c9iZMklvwMx6jQn5P77ESlRzv/3IdJCmvD92gpQXrJti6YDkpFfSY','admin','ak_487d937b7e305bd6','2023-02-06 10:13:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$zcguvEJX/hiLXnt4FGHg66cgxKGWA4EbeUrbaoSrcaXmti3st0fa8','user','ak_d5d026c26006bf40','2023-07-06 10:20:00',NULL);
INSERT INTO `users` VALUES (6,'root@internal.io','$2b$12$Q2Rj7bOuoIP3ZrX/5NmBz91n5ANKVpAfG7UqDvq3Iib7XkUscpA/S','user','ak_efedaa9dbadfc240','2023-04-23 10:11: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=16131;

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


--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=4905;

--
-- Dumping data for table `audit_log`
--


