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

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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$pSFWK7E9N.IWt9omYCHR5fcF1FSJPX8Mtg40.bm8nWA1UrBIbevLk','admin','ak_f944794a8597fd97','2023-09-13 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$kHZOviyJN6bLgtgUCGDEGL6ETwu3pse0s0tp7h4UK2gCikbX6etOd','user','ak_3bf8b12f38a3be9b','2023-05-20 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@corp.net','$2b$12$i49FQJWbYWx7PDDkjOf7uCq6a1A9ITYpH7wWH08RVPpYycSU8QT/.','admin','ak_b9a0eec331592473','2023-06-04 10:23:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@internal.io','$2b$12$KM2sNLiXbsiK3JmWCZPAqlFuZftiY8UFhp56ynXWJ87ydH.GMWxhs','admin','ak_06d221f36c9cf805','2023-07-12 10:21:00',NULL);

