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


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

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


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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$FZ5FOnFtfXaN5iJevG7x0UiulqAzaVGFlp1x8v.7g5Ukg/qEUqJk3','user','ak_9b283716be68b049','2023-10-13 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$jWxVe4rEEzRQoMHPSHL0bIa6aGgBdqc0XS4mELX5DuHbsjWageb/M','user','ak_b5529d961dfaf82a','2023-04-03 10:14:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$nxim2q8M7gAOfZPIsXCVC7uEVhrmBdAn8dHXpUMXbMYMY8jQN9BZV','user','ak_ec3b48d36a8202ed','2023-06-02 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@company.com','$2b$12$VLEq/eXPHStWi9F9BKlnIc7sA81MyjlFp2vJJhdd8nnl.DaCYK9Ry','user','ak_2ddf9ea61d1aac75','2023-09-28 10:00:00',NULL);
INSERT INTO `users` VALUES (5,'admin@corp.net','$2b$12$qwyjylhUY2P0ST3dNTm2ykld.EJvBODMtlNAmAXLUT.PnGxkJht.2','admin','ak_ffa4c023c84e6de2','2023-09-19 10:12:00',NULL);

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

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


