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

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

INSERT INTO `users` VALUES (1,'jane.smith@corp.net','$2b$12$MqBm0/xrFpnFyli4iNJ/AKDdc/Z8GIQNB/ZJ177KiXSiqJoRkj/hN','user','ak_fad3956bf6f76d07','2023-10-22 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@company.com','$2b$12$JDwf2NkvzJjiEYx47kmWp7zBqg.tNYVrAWv87vmbsHo5xwVstPImC','user','ak_0b2656b4b4a889bf','2023-03-28 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'root@corp.net','$2b$12$yERwIs4yrAO8F7j7fyctSRvL55MmOwlX5WW218jd8ASbZdot4G.lX','user','ak_79a99b83adab5f80','2023-09-04 10:23: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=49192;

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


