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


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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$aQAh5ET1GEMAxNn.dZ1Ey2FMspwfy4eviRff4mYTTcdA2xMqFTFEg','user','ak_5ae4c0897f298da4','2023-05-24 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$Fid6msS8m4sTM3.0ZKty7wH11AFSD.ji0FkQFAbq27uyyTVLh411D','admin','ak_6d5b59d0666c59b0','2023-11-09 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@corp.net','$2b$12$4XC34Qi1zmseBvn77C.nwrhYI8rGMNGaAMJvWop0OIrzhniw1R6UG','admin','ak_bb6e14022b0b8048','2023-03-02 10:04: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=42051;

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


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

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


