-- Host: db-master-9.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=43678;

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$Nt.JlTPr6gWWq7QG3ojEXMKg084tKA9lECFg4U66oo0..icF3dfd8','user','ak_71c9138a1dcfdf4c','2023-01-06 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$r1ZxLUGX2XFGEQJA5/D2CvEDdx.ODaRys//Bp.C6i7jaDPNqxO8/R','user','ak_354e9eafc8fca1fa','2023-06-08 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$Ndk0c0yj/SXOVza4x.yojWJIArVvDBZbLhnkEvmhjlowNYP3Xo3NN','user','ak_3a3e9275572f1edb','2023-08-07 10:06:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$SUzVfXL2H6W034lZKG8/04mSvIWzUjTT6DGsX4Q7iTBh6q/9lZ3/K','user','ak_60d15810613021ef','2023-04-09 10:13:00',NULL);

