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


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

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


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

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

INSERT INTO `users` VALUES (1,'service_account@corp.net','$2b$12$cYHXVdkmFWgvXq8ty5Qae9AwI.Q4rZ9a0l5sT6U.yta8eDvxt1TE.','user','ak_79c02f1f20d258b9','2023-01-19 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$JS/yoOLnvUWCG6F4bIJa59tH7AZk/RUGevy//3l2wiVcVctd086tf','user','ak_bb3e82a82203d356','2023-01-12 10:03:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@example.org','$2b$12$iW.5gwC8fmJtU2fHzM9wgd3wuxHwzRBqw41SgMffLL1B7nfOOeeaJ','user','ak_d78da365345ab3c0','2023-09-14 10:20:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$uenFTdXlO1zOv81wS4iivzY6a0IFjzrWd7uge8H0twEsOutESF1Ro','user','ak_b001d15b2208bdd7','2023-10-24 10:02:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@internal.io','$2b$12$wWtVgXMbYea5a3mV4aVfyJhwscnR2HfC89X09alpX0aRa2W5d28hV','user','ak_d7f82556f0f890ec','2023-10-19 10:01:00',NULL);
INSERT INTO `users` VALUES (6,'deploy_bot@corp.net','$2b$12$znrwV184RmDVcByrtnmGQ1NGE//9jepxA5V5Eziy2/Ajno2nQ3sMa','admin','ak_ca6b0ae1f1bc71c4','2023-12-25 10:08:00',NULL);
INSERT INTO `users` VALUES (7,'admin@corp.net','$2b$12$u5n4BRE9mkr0YR.Cof1depnracNq9TLd0qUnI8rQSDtHp2.XvhI/g','admin','ak_d044f68b2c83681e','2023-03-06 10:07:00',NULL);

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

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


