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


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

--
-- Dumping data for table `sessions`
--


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

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$ZKg2YnfcG4xU9jcnNNjxZ2llsQfVvTlrgelZMpAie4Hk0E.uVH2k5','user','ak_2244bf97696f065f','2023-08-14 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@company.com','$2b$12$pklYkfRVlZnoWSqN0gTQAhYJkPeYQWUKFK1sowpY3NlWw/YqQBB9Q','user','ak_f57cda490c88e3de','2023-10-25 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$PfXYZfqbedgrzW/Ztrntqmf/m2RHpk6N5TOu5gTYMcf6PSjUdxKX4','admin','ak_7f81b782ccf10b18','2023-04-19 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@internal.io','$2b$12$znb0MQe6WcJXCpeEyus5UbOWbX2G/zwOnzAPBJJRZWmgKySfGWPSs','user','ak_c9855ec41e4d878a','2023-03-03 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@corp.net','$2b$12$HnwP/.iLrzxTulslfRNTYIFm1JHJZ6OMWAVh8qCrLgqoGpORmI6S8','user','ak_57ecd9a218fd3bb7','2023-03-20 10:03:00',NULL);

