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

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

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

INSERT INTO `users` VALUES (1,'jane.smith@internal.io','$2b$12$W6ofYqn0yo6vkxPjV8KHZMTvmwSxdXDJIZ3a5PxwpDeXfC4EHLdLL','user','ak_0a0a366cc35c87a9','2023-05-22 10:00:00',NULL);
INSERT INTO `users` VALUES (2,'admin@example.org','$2b$12$g2UhQ0lt3oRpY0DStopMqzo.Tphku9bckM1AcfffQS/qOhdmEVHb4','user','ak_2c4dcee6925b7c9e','2023-02-12 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$.dCh9n.ig3EUadxPKVQwMRP3lIyjwyR68cPFBeF57S1h5arnAe1L1','admin','ak_160fa5a54fda2064','2023-05-02 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'admin@corp.net','$2b$12$WTdCoBNb0quQD2nCbpxJCn38o4fM1sqL3nDZwh5w2lznUX6olUrSN','user','ak_f1478c52838c6d40','2023-01-09 10:19:00',NULL);

