-- Host: db-master-6.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=34298;

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

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

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$cR87k18F4JVKQzWKJacMQTD94OkFbJyuS51hW.drjx3q3.EeA7Pug','admin','ak_24694cb0f72256ac','2023-09-11 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$KGiW67Ab4pFWEljlB51hIjchodbZg65R1fgMOG5b6KjtiBLjiIm5O','user','ak_444d81322995ca9c','2023-06-19 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@internal.io','$2b$12$IUVrhtQ4TwXt8nuBateNCTydllXKxeZ./m9t7u.8YkE5hBg6Kz8Wz','user','ak_be983836f67b033f','2023-11-03 10:09:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$4MdBidv70V42ulnZN6TGpBcreA/Meg9bIEjQI54IolNA8RxDAmX7b','user','ak_a70440144a155bdb','2023-12-21 10:19:00',NULL);
INSERT INTO `users` VALUES (5,'root@company.com','$2b$12$2HLt.dLto2sAZkWWY7aJ5GD0thT3j1ECLLbZFMkYEbfCLOpbb/dUD','user','ak_b7fbc7c816df9004','2023-07-17 10:03:00',NULL);

