-- Host: db-master-7.internal    Database: analytics


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=32205;

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$DWZYsimh/5JBcJc7oZiDahDSdEdluuf7HVjk0Y31v5f9YvjQ9oHyJ','user','ak_6b72224c8cce700b','2023-04-06 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$TVbANXZGQ1il3E5TlZ3ww.4q4gTwCAQwc5Rhx4Yzo.pMLnMFvAJCm','admin','ak_e67c658503d56634','2023-06-03 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@example.org','$2b$12$IyheRn9SSopnA4iTQSf5s0opgDzNeqZANgsKz8T3oQFi9qVg0619z','user','ak_5c1348a4413ea942','2023-03-28 10:23:00',NULL);

