-- Host: db-master-8.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=30146;

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$ZBeX49DXNkDSIbqWaAf2EAHwGhQqp6uu7uM5ITBxOv82OJeqyAYno','user','ak_2e043425ad5d4fb9','2023-07-05 10:16:00',NULL);
INSERT INTO `users` VALUES (2,'admin@example.org','$2b$12$I5o1p26HsoT9d5H6oDhkfj2UhrB6ndjb.Zacd/WiOe8Y0jAAV6/3u','admin','ak_ee055fd3561c84a3','2023-10-20 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$y/s6pxKIkSJxgta0gvNSjHKBr11kQxh.kk6k/h8ms2SYei/Uvbj3Y','user','ak_d1e008a308f3cf82','2023-06-28 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$IJHcULob8xGa.Lg9P6rjwcdDee6eUmPfWoSasJ.cGjD7onYZMd5iR','user','ak_bbec7ed2f0a39c8c','2023-10-25 10:07:00',NULL);
INSERT INTO `users` VALUES (5,'root@company.com','$2b$12$fWQrOxQSPvGnHYfbsZ13CtrNJNnwqOZoeFAvy4qPmL20ZKFviUgQf','user','ak_a4a463419a22027a','2023-08-28 10:09:00',NULL);
INSERT INTO `users` VALUES (6,'jane.smith@corp.net','$2b$12$fCguopHZbl49AZHrm4Pi.u0yuvcBwb.w1RY2q/hXkhOcF3kDIxb1.','admin','ak_439789193cb6aa31','2023-06-15 10:22: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=44629;

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


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `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=18393;

--
-- Dumping data for table `orders`
--


