-- Host: db-master-9.internal    Database: webapp_db


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

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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$S8RjnzYti9B4Z6T2HGHyem6RgAz/5WesQeBkEoztY8qikBLOxSzDl','user','ak_d3e54985e72bebb0','2023-06-17 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$Admgy0z8R3/H3oaAaFlI8pdQe4qlKXGQ7FuM7H3bfq7EPHzMkMN9M','admin','ak_681d21d1c4583fc4','2023-09-09 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$kISgR2yQx/aXZEbtn2qUdf/QqUBtldvT9QucWHUqu.9QyaP9r711C','user','ak_46962d378591e6fc','2023-12-19 10:04:00',NULL);

