-- Host: db-master-1.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=10878;

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$GOJ9G19XCqt62Ek3lJA7CRETI4z8mdbe2L9u0OGLuE.1M7tDychmZ','admin','ak_93bd10f4a733c45b','2023-03-17 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$JAnhSy8FIPUToMioj5Y/EhYx6Rl5UQ7GeuHvK9XkKVdmXTPxOSjTc','user','ak_16a89dc6d3671467','2023-06-02 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$PJngeshaxpIaBsxdvqHbAbSCaw5HJLT1cxlPW7sBEmG5sNz1WaPLg','user','ak_82718dcc2e201941','2023-04-28 10:10:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$yKsu8fSTsIUwO.SsZ2..EtgQ6.dldFzMUS/KxeErfZu7L/R8q/MIF','user','ak_803677328c468564','2023-07-23 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@example.org','$2b$12$Qi2JIA5qCMMKAXvbNlYWCRuqd9KaGCGUuU0fVkdH1sTlQHnKKbqKl','admin','ak_a452a4e8aff2c70d','2023-12-06 10:16:00',NULL);

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

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


