-- Host: db-master-4.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=17326;

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

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

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

INSERT INTO `users` VALUES (1,'deploy_bot@corp.net','$2b$12$paQgKDwAibsAxx0UrTv1Mz6RIOeQI/0Ou9j9V.tB.Iv0qX1/BV9ci','admin','ak_b3fcc201b20c2d7d','2023-04-20 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@internal.io','$2b$12$MQQikm9GcPQOtJP2fS0zydVXeDbbciNDQJASLoYVYSPAw5SFdU4gp','user','ak_e053f9bfca6c9507','2023-07-12 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@internal.io','$2b$12$.X70NYHgrB2ByACXqGWMiCjqpRESDiL3BHr310xmvL5.B8XjtQN6B','admin','ak_0c954f701618f581','2023-06-02 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$x4fVbuU084FHCj1BU8p0eHsUaxSJ9nNCaPZjtG09m4jkHzXPKEbHs','admin','ak_44bc238231e0cb3c','2023-01-18 10:16:00',NULL);

