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


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

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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$.Pl3XwtDJzPwbYi/hkKTg0L0uXqAxqzS2XEWxahtZ3VZl6.yenBGK','admin','ak_448bba7a9ddbd2b3','2023-10-16 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@example.org','$2b$12$MBsHF6B4r0YWmNIw6A1B1WiekYgxtqyMAUcErK/2KcxmxKsJhpdmF','user','ak_f8c66106d35356f2','2023-04-26 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$wPcAVzdJdfgs9Krozs6NirhxBSgVKjMLF/JOPSkJfhBM1JHNYslIe','user','ak_fdb376cb7ab5a2fc','2023-01-10 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@example.org','$2b$12$n/NspCyzXetAGjTVZnd8eO8S4BKisZ2F2FexJZlkKtd4XLI0/YcWX','user','ak_ca9917c2e5d9eb74','2023-10-14 10:15:00',NULL);

