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

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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$pbf6E679TMON9XFj9dU6kBYoHdBXdETQMjepM3A1ZW6763o9UOrxI','admin','ak_20f06e906c208dbf','2023-04-24 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'root@company.com','$2b$12$DyTdqTUF.EzXmaZoa5qZct23HvloYrAGi173sSxmEqu3TqKQJo7D4','user','ak_bbb224738d016b4e','2023-09-18 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@example.org','$2b$12$.rrmoAhNG8TXxSbgrklmGCLDm5umucCNxBR1RDkjy78u3tEQoDzT3','user','ak_65ab020f913e547a','2023-11-23 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@example.org','$2b$12$g78LLzVHM5ZVPNMAH.1H37780tLXl4yp.ag4hfTL/mrMbW9DP7dZI','admin','ak_d7451684a9589612','2023-06-19 10:03:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@example.org','$2b$12$vcjF4VWdebY39t6YkX.nU6RgIUqhl3T5sDiaTu5dF9qR1TtvhgeKm','user','ak_ff8155f83444f3dd','2023-03-01 10:18:00',NULL);

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

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


