-- Host: db-master-7.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=24934;

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$76CP9sruNMXzHvd4FEITSLNfHT3.4oQhbLIZ0TZOT9bhV0.f8peP1','user','ak_e45f46c5c4f9b0d1','2023-10-07 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$SYDL4Ef1T7d44zFpkp4rYPH60qbMtTiHdj5BA4KJ6wN.9YNbjwqsx','user','ak_dbf8da520c12f139','2023-10-14 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$iIKBwjbAvYeWAk12zhFYadE9uMC8ZggTwcvssZ1DZwRxaj38Wxza5','admin','ak_415013182908e4ff','2023-12-11 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'admin@corp.net','$2b$12$NnsniuzfkwJ094pvJJkOupeK/k5Ul6GJ63/hzao6rqBVSJrhBliwG','user','ak_a7af1eb1d0e66d11','2023-01-17 10:01:00',NULL);
INSERT INTO `users` VALUES (5,'admin@example.org','$2b$12$pbpDFLJyUvcFjTFFJQe2aFTRRtDsuEKciAEeR64ZBxghKkeQRPs0s','admin','ak_9f8549fe11447113','2023-03-02 10:02:00',NULL);
INSERT INTO `users` VALUES (6,'backup_admin@example.org','$2b$12$dkZmuAfDfcY8bVTiwhIDAk6zduHc2htZ52lCE0O/UWALYJBPMgaR1','user','ak_741429c4bc780ecf','2023-07-17 10:21: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=2178;

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


