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

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$VyG8JDhbmmGlK1pxl4O4EXo6XESpORNrMDHj2euAM0aRh8J5RfIso','user','ak_95414102efb4527d','2023-09-14 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@internal.io','$2b$12$9h/JPWzWnPrqlbIZ/kMePNGIgWA64/L1xnuHmtxONdIQMYfAWGcxU','admin','ak_d37001434eb2e749','2023-03-25 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$V0.hl28X5eKxBb26Pmgb/zXcguNlTtkbz0G4qsiDxChfql6XIqW0r','user','ak_5a45e39dd86ac917','2023-02-09 10:13:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@company.com','$2b$12$.c45D8a4TuaOUV4Pfa.c16viYePOILjHA6DDu6eCxTpDq6.cx/4y4','user','ak_c68b2775bc00b88d','2023-06-26 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$hNvIzvExaTur3v6/F/1mBRczDIZOEhG0YreaA2vcFG2o2AC3DKpH4','user','ak_5a5199d877b4ea3c','2023-11-12 10:14: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=1175;

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


