-- Host: db-master-4.internal    Database: ecommerce


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=16774;

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$5A/jO4zNXfSC91SF4iW.Pi4eBZpnPV90wZtMsjNJsro1hJJsB5pC6','user','ak_79f90e3e6bb9799b','2023-03-12 10:22:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@internal.io','$2b$12$0Z6RpIfAyKOaESv4wtu70gQNwrxPWo0IDJECjScclqDzofLBDimZc','admin','ak_5d44943c54ae7e5a','2023-03-16 10:03:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$YU1upvSta6yAXe3ZEWTx024ZomdhzphG..oFoRG03hFZb15azIC.R','admin','ak_e9f7b1ee317a62de','2023-04-12 10:12:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$caI0kCVjZc25kaPtbla3X0ro2pcMC8BdNVPyGW672B9PVTOimd3ju','user','ak_421b456f4341d1c7','2023-12-20 10:19: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=11675;

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


