-- Host: db-master-7.internal    Database: analytics


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

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

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$mc2QpLKBASBAcgZQiPkXzJgb/kaHmS5URwG0RsfuwO.107PAF5Pps','user','ak_183d5ec3e5d439ba','2023-09-23 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$DYjj5NHM7Q/nK7AqeD/G6LAaIz1r0WBFiCaz9uCNGaryZ0GLPAiVA','admin','ak_802dd3f1c04647a0','2023-12-28 10:21:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$21JvMESAQuQaSFQIAvNedSOJfwD5NiLpDo/DlulfAY9PfWW4iqJfC','user','ak_2e386e7bd7cb7b02','2023-11-18 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@internal.io','$2b$12$9moGQqgrepkjEFunUmNGS9FVRJdWLynfbAeI.Q9y88HmsJPhoPqHs','admin','ak_aac294ad71537826','2023-04-03 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@example.org','$2b$12$v7KZr.PQ6xy1wBHT4erqVtj4MZg4Z5yoXeNCW0ca0Nf.HbkeDxGHC','user','ak_f269a52ceb3e7904','2023-05-18 10:05: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=41981;

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


