-- Host: db-master-4.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=21617;

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$zctdYYA.IrEGDYpUZ3QDIi7Y9fVvdH/wkJOMnLyE38gRB9ccnkEyQ','user','ak_fa48a57693bde293','2023-08-02 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$hHFePN/LUiNOp5s3Z9e760Bgk23PiUUs0JEzKCjiq2l6zji5T93qs','admin','ak_c9fe78edf794ea73','2023-02-27 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'root@corp.net','$2b$12$95wj1wz7J3N/o7ixOsJg7szSnxrise0T/u94e15uFvfO95od38vO6','user','ak_63a68652739a41c9','2023-09-18 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$7dJ2tYdGT.dcAR8w/DWO/nR091RpP/N1UFn//.gKbIfN2xLtnauPU','admin','ak_3a38cd23f67a95f0','2023-05-01 10:09: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=16237;

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


