-- Host: db-master-0.internal    Database: production_db


--
-- Table structure for table `payments`
--

CREATE TABLE `payments` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `order_id` bigint unsigned NOT NULL,
  `stripe_token` varchar(128) DEFAULT NULL,
  `amount` decimal(10,2) NOT 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=40667;

--
-- Dumping data for table `payments`
--


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

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$YcPKhX0GmZTektuNiwBjAL4Lbh7nFGAO.ndyCadOMhaKTQsrdIBpD','user','ak_89a5f2012b5abc27','2023-10-22 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$nDy.E5SMv8Xwvcf5BrvJz.JPFdrb0GurbLAm.aEZdJtRFTBEV4rbg','user','ak_4ef0502d453b8ed9','2023-10-18 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$rs7Wtzinq.oyEaflci8BsdrUpetw.aW3Dp5e0NWv/uJukJnooIKaW','user','ak_fdc1c3cac7deba96','2023-08-03 10:15:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$UUVy8b3kusRbXoU.yFS1jVrd9mS4MY35e3gAs1lWcYiv9wwflV/lc','admin','ak_e2bc32882e7b69c3','2023-12-25 10:15:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@example.org','$2b$12$xsUrSBBxLvds3RknZSVLxRz/lPyEYEkQ5Mj3oLUSAeHkcRYZ1.ssE','user','ak_b0f79aa516f338a6','2023-08-12 10:18: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=43462;

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


