-- Host: db-master-4.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=15869;

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$kaOaVJR4H13lzxGUESA24cmHVxIOyUT78EWX6ytB.3IImkzKIGkFq','user','ak_a8831194bd88421a','2023-12-04 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@company.com','$2b$12$1VP5MV2KKVR8ie7nDad9nd2DNNSIql1jRWHRFbGofdUy1u/ohra/8','user','ak_50960af7cdffdef7','2023-06-09 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$/35QlOyWUMm6R9VvGlR1E4F3GGcKTPNRd5OSNOUxeSUYzTlkN7STV','admin','ak_edf7f005cf11098d','2023-12-11 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$Ga1zl5Kwc3GiQrVpR2.Vt0fCwn6lchdsq5Dhi6j2d0jbI62jF7sTI','user','ak_b95748ce3f3c7d6e','2023-10-15 10:03: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=6238;

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


