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


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

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

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

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

INSERT INTO `users` VALUES (1,'john.doe@internal.io','$2b$12$JPLRk/jw9RWA8v5Zpz0N/YwSACmuLORrK1OWdurd6IUizO3lr9lNd','admin','ak_d9f505fe7bdd8a8e','2023-08-06 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@corp.net','$2b$12$HHgdJ/Gc0Rz2TtotQV.FTKBxGWNB.nuySXPYuSvTNjgB1iz9dZC7l','user','ak_d945b48f8d6be6f2','2023-04-16 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$5R35C7Q2Sk3BBoP8z5mvwg13AK4KkRCKxXFz5TqNHgVkrTX1azdKi','user','ak_d5896652dd2a4e29','2023-08-27 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@example.org','$2b$12$qh8wb32b84RItDieWciOmdv.FZciltK1JhkkXf.ppIWszQGO06V/1','user','ak_cf057068197700e9','2023-01-22 10:18:00',NULL);

