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

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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$uHroTsB5LQXXKL9cWGz8vHqPUfi05ATRz1K3UvTEmY1kIrkVW549q','user','ak_9fce74ed6b5d7527','2023-05-24 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$aV9YX2n7q1305go7Ai5k0ztH5eQ2NkUqr.kHUAXMWS/6S7oWXKxKh','user','ak_3883d6ea4c856a0e','2023-05-27 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$C7inkRoMAHGSXYW6z.nZ/291m4Kl/.FVr5G92elC5KumEGaCLw3gf','user','ak_eb9b17ea8699781e','2023-06-18 10:13:00',NULL);

