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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@example.org','$2b$12$RopUfml10KxkpCl3cTRAcuBkLmoE5T3LR99tUfqrhuzDj0gIxqNPO','admin','ak_4188b844c9def73d','2023-03-08 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@internal.io','$2b$12$TAdmnszghugF7D2xwhF1EmTw91m7Uj5SowazM7FDSzdafkft3DH5h','admin','ak_4f96cd992cc7401d','2023-06-23 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@corp.net','$2b$12$uEIItSDCpcMrl9y9Wo8RGxjNBnE8bclU6Yqb3fNg8lXCMZErIKdZc','user','ak_9c770c24e3e84203','2023-03-07 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@internal.io','$2b$12$Fn1fR49u2ynbpcpf7yzYZJquV1luPosNJQVThM6k4fA14gP6DTeR6','user','ak_967a947d0cbde64a','2023-09-03 10:21: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=6684;

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


