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

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

INSERT INTO `users` VALUES (1,'jane.smith@internal.io','$2b$12$7T79ru/GCW77oT2vValGGwgrktliP3JSlwa7st9hXSnDkwDfRpEEM','user','ak_f17cb695b3246464','2023-09-07 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$EZPclSF.3dGoTENTu0.d.fweuY0zspuGh9TpHnKDso6M.KfeRHt68','user','ak_a5b3b0e69ed2da12','2023-12-22 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@internal.io','$2b$12$t.Ujsr8Nd23eZNJh0Fpi0DI54/NbYL4GLNWS8rSCC5mruI4gZYpa1','user','ak_f6b25457e244dd6a','2023-03-02 10:19: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=39026;

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


