-- Host: db-master-0.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=48832;

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$kSyHepLgWCQN5vRq4tGolK24gbjVi4DhCpuo6B2w.3yQ4lWmU9VP.','user','ak_3470ae9443f5701f','2023-05-03 10:01:00',NULL);
INSERT INTO `users` VALUES (2,'root@corp.net','$2b$12$3INDXRJEmo0tJf5TEPatgkyJiPbeRT26LYkW.3jMOC.EWxJ1mqEtR','user','ak_35533543dc1c0305','2023-06-12 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$jrpO2DAI0BfQs7FrNi9EHY5OiGv3BKQWWfChmD854HWaRp4H/JY1g','user','ak_bddc5e596ddeeab5','2023-05-27 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@internal.io','$2b$12$FWkqDbDHFmqnrNy0CoNsLD.voxG2rVWG/RsxJ3Ye8sNnEHQuCXhSN','user','ak_30bf2ededb785e05','2023-08-17 10:11:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$GClrmaNnNVmWv202rEzCxlU3d48zr3ZKv/PTDc/kto5HvHqVyMuG5','user','ak_283fced0ddf00398','2023-01-11 10:04:00',NULL);
INSERT INTO `users` VALUES (6,'dev_ops@internal.io','$2b$12$/lK4ugkCBREuCAF1kOMQVm9drlPJxTFqVmNRq0SPXWu1RH7HPENCZ','admin','ak_eb5eee4cb780b293','2023-03-01 10:06:00',NULL);

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

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


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

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


