-- Host: db-master-5.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=50424;

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


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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$wB43tTWDqioSuO4xCOmzIWI5xtLD39eYM0JzRWShjHic12cDVgW.M','user','ak_bc92a454c70c824d','2023-09-02 10:08:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$rdImG40jyO2BGzEwv37e1b4XhSmOzza1cadyEujN6yRPu/E.Rg4XU','user','ak_d8561bf659ff6698','2023-06-09 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@internal.io','$2b$12$YhXMfT4zFumlZzT9AjwZqMdsmDhh1aANxLSiCllt9YQzR52/lMtDc','admin','ak_39c7cb399858b7e3','2023-05-27 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'admin@company.com','$2b$12$22J64NGuHrhiJBmY86lGzgRwbEh6AyRmszuQ.RU/r.hsZBGtJePFl','admin','ak_e9de8713bd0dd4d1','2023-04-28 10:00:00',NULL);

