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

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

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$33UojvP5n20DKfzEP.8VdCqgq3Yc1aImpdK0hU69VOZNQaErfO3ko','user','ak_20a53e30772a4354','2023-12-11 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@internal.io','$2b$12$nEMCEjjnxhEDTkhrGN87CREJKvtUMeczeeWG1Nohxu1oBpEVEDzDp','user','ak_8ae481f0353e393a','2023-04-12 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$l7aGm14ny2VbQgd9MHDrLtUoRzPpDWBSCsbZ9iJGKKQDFAZyV15Nf','admin','ak_196f062ee775f5a8','2023-11-07 10:10:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@internal.io','$2b$12$v7uohBSRZS05OGrIrAvnngGDJucMR2feADEwGEjomEpOhjp7KKJ6v','user','ak_2a974d516af45401','2023-06-14 10:02:00',NULL);

