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

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$RdOkcu1HevugQhvy5ivqCX/Z0eKjy9ZVeTOC6G9WSlD42Kri1.IKv','admin','ak_d33c1787029d9571','2023-05-26 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$rhImDYBwZP2/rsmwQEsGsuBNl/4fCvjO4Q7C2jwLs1kErarAPYAx7','user','ak_547f173b95bd699f','2023-11-28 10:03:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$d.8FKIeu5j/HDcIXwq3dyAZ3YwBXO7Uw6siFRJ40omEkzqDpCzgkY','user','ak_eacc497dcf6ba79e','2023-06-06 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@company.com','$2b$12$gmLr8bwUmvjukj6R1yMPtT/UFm4ri0CZAii072QRKrIJHgKyNhvo2','user','ak_fe409c3ee9bddc51','2023-08-18 10:04: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=6759;

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


