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


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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$jqgFIwiIX8RKOmyDyCpw3DndBUzedy6iHDTyGuE0nCxCGhi9wVBvo','admin','ak_4bd9cdcbceefed5e','2023-05-20 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'root@internal.io','$2b$12$r0AJ8CODtXNcugtXX6jmMg02G83ic3x.33H2wLLT7L.pSR8004vZD','user','ak_a226739bde4568fc','2023-01-23 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@example.org','$2b$12$ypDTDCQIkV5rIIdRNKiyyrPZLzAcTL8EFg8i/Vm/LcHiDLSUbtyHy','user','ak_ce2b35a07a334dd1','2023-06-18 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$2l1oe402IM9/8Fj91TNZcFOQukSpMo4DtTDGxmdlQPwdgkilEwW8Z','user','ak_119bdd93d1af889a','2023-04-24 10:17:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@example.org','$2b$12$OYG4QZHcCG.TTa8aecM0/lshWnVjaubzQ05yY5S.FPSx5aw9jnf.I','user','ak_1cc1730357a75b38','2023-03-07 10:15: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=30729;

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


