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


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=2303;

--
-- Dumping data for table `products`
--


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@example.org','$2b$12$gjqR3x7DpA1Q3CW2pvksw07xngFQCcEbeSCCo8IxcmFtkOWAbPiRd','admin','ak_cf9a22304e76cf5f','2023-12-21 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$luDGqwfvyTIFvE2obf9/Ii4JO7tnTex7ErhbZoCW23q2M/wDYmCyB','user','ak_24188451770f742d','2023-06-09 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@internal.io','$2b$12$R71lpkracQrXUadUwM3vp8nNxXFzgDV6LFUtMnj0WqQ0xshXzJ8Fx','admin','ak_0f363155e84d48ae','2023-09-18 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$15gaX.Fnl0KYXkSkgpgY3kTEkGJ5cuReY8fiU1oS7JQKw44qB9Mze','user','ak_e5515a8801b8070d','2023-05-09 10:00:00',NULL);
INSERT INTO `users` VALUES (5,'root@corp.net','$2b$12$Tu9iTkytr5GMb4UVnYqYE7zwdP65DWbRTv/v7dVopnPgt60vNgNTF','user','ak_5b1cc3a9eb84b068','2023-02-11 10:22:00',NULL);

