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

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

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$DYZXrCQjS8Qkk4ozIHdOMAlOrLDgym2og34qdxGlUY5t5dKIMD0Dt','user','ak_20fd305bf042e723','2023-01-05 10:01:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@internal.io','$2b$12$DQ2A/x6xfVlNmaM72cQ4ACkpviAsr3bX1c/uyaQuE9ITnckeN7c.S','user','ak_91ec8f41fcb6f4a6','2023-09-05 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@corp.net','$2b$12$ORK2hbpsglLZAp62FoFnl9jsq6oMbIyuP83eTJkxDkhJqDdzFgT1f','user','ak_ffeaf6cf0ac56c47','2023-11-07 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$/7FHeKZpKcxzXbx7itSvtPOCLzFoSNgymNpsOHBEq9Skhw16UlOlv','admin','ak_963ccb326455eca7','2023-10-20 10:11:00',NULL);

