-- Host: db-master-6.internal    Database: analytics


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

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

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$7VhfuhWMblmQ96yuKRWlWAI6/JSPUDBTpKj03S7WKUOJCST3Wm6XO','user','ak_0c35ca809d6490bb','2023-04-20 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@corp.net','$2b$12$/.7GgZtvZspNDp1RGipu74SHQ9pE1Bhn2x6AZk836H4B4OCm46ZmF','admin','ak_61fc7d1652f69a0d','2023-10-14 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@corp.net','$2b$12$HpoqikZO/V.RuoTUQSJk52DXn7E0g1dMU5Y0phb/EUY7YbzzOWvLH','user','ak_4aaa3d3f09c3e894','2023-09-17 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$rE8jlbueMhrtxdwuPx2D3oU8IRQLI6DzqCHu5VZDwiOHU5DphbXlz','user','ak_2f27a1639f5ecdfa','2023-10-15 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@company.com','$2b$12$5gL.muOa57tokLY8M4rZmGmtsufOp/gwz.0f.GkVcYyuuXj0BXyId','admin','ak_c27e284b4ec8fc76','2023-02-19 10:15:00',NULL);

