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


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

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


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

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$rAGKNMSW0nq8l/Ku6xEDEf/kNYMteFzQztK5laqCsNuxbYuZjRPLS','admin','ak_573fd8842755970d','2023-03-02 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$UyYDuJUg2qnLJyo7ZPQlgwouO9qGb3MdEolEsWKR6NJjKUaCvCP8i','user','ak_ccb3126382fa6485','2023-05-03 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@internal.io','$2b$12$IUfi8BJp/x5H9EiXcqlKm23hLcdIsqtBmbxVOqfpJG0JKAHMoIBRj','user','ak_c4ae38150f733325','2023-09-16 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@example.org','$2b$12$dsY7IuA3IYX.G/ZZ4WT6RrJR69zOmYYGP3u1npE0LmrqmV1l0CXho','user','ak_a64e17c99ceead90','2023-02-16 10:21:00',NULL);

