-- Host: db-master-2.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=21334;

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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@internal.io','$2b$12$0oadVBawgoe7cQxmg3O/eA27gg4z0hJfpWet.C/RfIxRWvzost4bA','user','ak_3a6429d231b77082','2023-11-02 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$bsA8mUmuaGK5lGKqAeT5IEiHfajjA2M8tWAgsXeTelqACP5AU4ZbO','user','ak_77b9ebd6b9ff396f','2023-04-06 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$yocRlheORUrxi3WSqUeIThL/kExc8v/dCJTBuryr7l3bXsJMLmBJ5','user','ak_564acdf9630a8633','2023-01-16 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@company.com','$2b$12$HNWK3Qu/NQjs2sYPuGiZW9cLM1gRAQsqyROjEsnpePig3YsmVzyqe','user','ak_eb689d153f7e83a6','2023-07-06 10:15:00',NULL);

