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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$p0qcOHShQQdHK..AD9QZL2P0nsQIYLRw8.N52zgPhjdtCYcU7Cd1.','user','ak_2924ed7b8ee69296','2023-02-27 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$BLtMSmE3vMjzJQjfpSRDlAnrG5Md0VJf7nsd5jSRvPtoPAQP2QmUK','user','ak_a26de95f52cccdf4','2023-01-21 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$Zu34uH.aAECf5Fq8JGaa94srWLQekWgDMbEBxz5kZdTL34gpw7xPV','user','ak_bdaa5a9bb6390978','2023-06-09 10:20:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$.eWLM49iq6ZUMBtQRbcEyVh1MwaE9vNaq3f3OHfohpL8EdWF.G/2N','user','ak_981e136539c6ee6c','2023-06-09 10:04:00',NULL);

