-- Host: db-master-5.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=50355;

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$yVJYVrCYXKF2l2YV.Q97NEWejGO8QxSyOJgYvHnEUnJ/aSv0lGLNR','admin','ak_f67190241296083b','2023-09-20 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$QYiS6s7sMaJZtoEmCaZvvg5me9Wun.hnVWy0Jk4nH77bIEytNJE6U','user','ak_445b639dd6c13e83','2023-12-02 10:23:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$GyLmRlJZsP2l9ioy.conm.JDoH/.vtigptYwVVyKMx2JXmv2tZk86','admin','ak_2ca68803e22b1678','2023-01-23 10:21:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@company.com','$2b$12$O65vppUNX7uOWUbi.tivo6QbjdIMR2XP.L23ZtkrR/eJG.7jRbITv','user','ak_1c7d1a423028e38b','2023-02-13 10:09:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@company.com','$2b$12$PQ9wk7fAyQPCULBdu3JOhkT812GTo67/X35elJuqeuQ.RxuUhNlq7','user','ak_fd1ad04a934b39f0','2023-11-28 10:14: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=31547;

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


