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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$l2BT5u.goML.WJzlA/mL0PXdayTK.PT1rS6vPhE2eT1JNff8DDPYs','user','ak_ffdb4b386963bea6','2023-07-21 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$/QbRGa2qguuKHiOrfZFqVg0sfZoyq2gQ2Qf.hJiUxuHWvLnBGEpX3','admin','ak_e425249ecb6b091e','2023-08-22 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@example.org','$2b$12$BU58RtaXBwfsQdRspNZRfeLjNEHDtNnQHKloStF8LClHTAaJOmzHc','user','ak_cd9d6c3e0f8d7520','2023-04-23 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=3201;

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


