-- Host: db-master-6.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=35087;

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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$8o77KmLCcVtlBS8MC1dd0VzaU2VdgY4Syh0DWwhk2pMNGR2VNwWoG','admin','ak_e45e7408d348f819','2023-05-18 10:12:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$cn3JbWrOfQCNeevzdLrrFmUfchU8evXdLToJu/Aa5wbWg4NwgdAQR','user','ak_bfc0f11a75b67ad1','2023-01-16 10:08:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$qDC72y.DnmSY.vmGGj8/op6GEq.DSvfQmRTeyv7hOoCioQNifhKLG','user','ak_97bfc0e35a0cfe64','2023-04-09 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@internal.io','$2b$12$ZnO/AYoHDzSRiWrf.lGl8SbyKvSFCLtZY1k1eO3npuG8urPrOolZw','user','ak_34ca1516d096239b','2023-11-06 10:05:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@corp.net','$2b$12$zaulq6QkN5KWGJ.ulX9y..C.OSJXUkPQ2ivI3RgkGYPOWmsTt2Aqe','admin','ak_0b7d52c23477f4d8','2023-04-23 10:12:00',NULL);
INSERT INTO `users` VALUES (6,'service_account@corp.net','$2b$12$eFA1J69OETMmb62CvK.IlA3O.cwUDJ6YmAPT/JJbmXqLg3xY7xltX','user','ak_cadecee330acc726','2023-07-21 10:16: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=28339;

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


