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


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=19277;

--
-- Dumping data for table `products`
--


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

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$i5t15xZTs7satKyz/3E7OyI.ulJoWAeJASB0cQOVLvoovMTjM5g5p','user','ak_8e99368551d4e4cd','2023-08-27 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@example.org','$2b$12$KLzWQX/PD3SRaf8aa9YUAyAZu4h1Pl.cBm5NgjZmKmebmUxTLpFxI','user','ak_64fe35d22ca0d53f','2023-03-03 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$38HmNj8Qti0/t8FWSDd751frJ0/SNprpLnyfKTm.xd4quPXFN0bMx','user','ak_2c4cf43fc9f0b991','2023-07-07 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$WBDyEzjgo9Yo7UcHPNpHw4dHNRZVjlAGYAXGgUtkI3MBMpprhPdNX','user','ak_44cb34b2b665eff2','2023-12-21 10:06:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@company.com','$2b$12$oeDEgvCjjZF86UxraDlrwfM7fUAXUgx/rTXIqdd0zZfQwJ7rTNE/F','user','ak_7dff4277c12e8b46','2023-06-05 10:09:00',NULL);

