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

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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$JcQugO5JfSppUIDavNIXxktcOal6VjRQgljoNvmKqFUWMbC2/aYp2','admin','ak_15ec1c3c4615b175','2023-03-15 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$.UMeTQrzojTjx.T46kTVsbs8PBGZN7gwkUZxDtcgPaW7rHYsDNe1z','user','ak_5e9d65a293e64aab','2023-03-12 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@corp.net','$2b$12$NbujoC2JVL8sigJoxKfYw4Ov10q.gK2gE3U1u5xoQvgkR1hsj1lFH','user','ak_314fac982186b6ed','2023-12-14 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'root@internal.io','$2b$12$eSxj9BUhYW5VQw5k3ouVvH6Ex2pGgXTHWGfAS3jIfVh4sce.wLumu','admin','ak_e9513a3722cb3366','2023-05-10 10:22:00',NULL);

