-- Host: db-master-5.internal    Database: webapp_db


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

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


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

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


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

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

INSERT INTO `users` VALUES (1,'jane.smith@company.com','$2b$12$n0CPXOD3nysOGPHx35KGdjagXGSTQ3MXGx.rmeXnY7v.8PjxdR49g','admin','ak_77ff62a66f395a7c','2023-10-15 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$ZS4yMSDx/awk0gi893aGLc4sJ06iCVc.uuPv.VgmrgLSbH7w5WONB','user','ak_6fb21ed778ff4b50','2023-07-19 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$DFcMJnW.oA2Dpp2nZbYjQW5Vy4G7PeXB3lSi5SkNmsFGwxvqzwby9','admin','ak_4f39057df690135f','2023-01-14 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$npNwol8inH3tDlHYno4EV9a9F8E54fFFzuXCtKEaC26bk.hesybjO','user','ak_4fb5407de607957b','2023-07-25 10:17:00',NULL);

