-- Host: db-master-0.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=37240;

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$ndOAc1CkAEPF0GTD4LkMKFZHPc0oMOil6VgmCw0Lmw4HBaThlUuZN','user','ak_b1c9b424940b7109','2023-03-03 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$VPjAXnue1YZrU.9T6y1vU4R.KTJG8zc10cuf/DKomv2pju8RYAL.v','user','ak_70d805d726a10aa2','2023-04-17 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@corp.net','$2b$12$3nwv5VDygTEdLT9wLKhxifxkS.5n6SsNznLVtjuuW73WxPGgEY/A5','user','ak_ad13d07ba535fd43','2023-01-16 10:23:00',NULL);

