-- Host: db-master-1.internal    Database: production_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=11383;

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$FbcO8nYh8xmoldMdpr90a9WYxGiuphTObOjWkHZ8IWHS2PitosjZo','user','ak_e07dbdebb090eccb','2023-08-12 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@internal.io','$2b$12$pNwA0x0WhidO0kXxrw3LUEa42zuXOO1MYNZrXgmG3/DquGy8XRO/s','user','ak_eb76e538049fecb2','2023-10-24 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$ErM/hkOpCfoBXeNH15rrSm32bWQum522NeTdjgwX9nMqkvayFAHbI','user','ak_8d1724cb3d56310e','2023-03-21 10:19: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=40039;

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


