-- Host: db-master-0.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=45524;

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

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$bQcfZAvxmanuUkIAkMDMZSxF.QsoKsxwM8dVPEjR7P07.UXoYyqdA','admin','ak_602aa01f6837152d','2023-06-23 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$GhPTwNxw8R34SBhM/caT5IkHRuSEAVqdg0fA66kLA8/mNB1wL6rBT','user','ak_8f879db8bac9b823','2023-01-10 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@example.org','$2b$12$2kXfjEx/ijJIRY57Kdjyh1MYLKMAwksuxeQ1GDi4Fr4CaBOBQiWBA','admin','ak_2be0f0b8a8011067','2023-11-16 10:15:00',NULL);

