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


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

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$WdVf2enuLlDJmavwNvVFmxas9.lggjD.GOt7oUksJr8F9LUpGrOUm','user','ak_12d88850bd901ab5','2023-08-23 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@internal.io','$2b$12$7ISi3JcFgRPLxE2vpCPcnh/7eOG7IBSzsSdY6YTSYSBPkoCK/L/yE','user','ak_8cb3a82dc3a644ca','2023-11-26 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@corp.net','$2b$12$srGhpeXBQyzYhOrzruEjaoGqdFZSFlXTaTve3.KVHqwNbLkQaKDkV','user','ak_58721fc63080d26a','2023-07-17 10:05:00',NULL);

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

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


