-- Host: db-master-3.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=19947;

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

INSERT INTO `users` VALUES (1,'john.doe@internal.io','$2b$12$2yGdyEVReDuelchxhpC9HPrz3G27Hj1NPxUaec84TxjHHBIBIcMg0','admin','ak_808cf958a33b2c65','2023-09-26 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$KOp6hmeVaWLfy2K7QaBVSFU7dMGOAzzRagQqZRwqXxzW7i8ndPBzJ','user','ak_91a876f5ac6fdf59','2023-08-26 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$60RVgWoteRGAH.w/75vTDs9xkr7Dn0Xp7gDGHH5eCnyrZ1bBhlRMT','user','ak_be595e3ac950a057','2023-12-07 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$UxMKtAbiDwqucDU6bsv4wsXe/F6j54DIiXHQOWS94lZY4GIPLRQdw','user','ak_795107c445236778','2023-08-07 10:21:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@example.org','$2b$12$Gjm5v1FtEDLxR2pew5Y/9XdhhkjDShc6Ayrv9TTz1Xcy4ljI9OTEH','admin','ak_9e6aa4d94b2bb5a7','2023-06-15 10:21:00',NULL);
INSERT INTO `users` VALUES (6,'root@corp.net','$2b$12$EeufwQbrdlW/sni5I0S1UhLoHrlXXRJZPx7E.i..W38ix8hRCWVVF','user','ak_6e2fd46c83b03a57','2023-08-01 10:10: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=36530;

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


