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

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

INSERT INTO `users` VALUES (1,'jane.smith@example.org','$2b$12$qzw36gdaNDZOn/t7TvgexlCWVRfbPKlX6/53vOIY2.0qmZRI6NgTF','user','ak_6f02b62495a35452','2023-05-15 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'root@company.com','$2b$12$EcymvPwkoS/VolspgTTp3Fvb5O1r2i7p2JghygCXiWK0MKEEHUj7K','user','ak_b229417a7446a411','2023-01-22 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$Pua33y4GXWLYHX8dHOtgx00mP75dOe1U542DLf8IVLo2wvFxkwldd','user','ak_6de3bf6810c1923b','2023-12-04 10:05:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$l8nX6j75Li6R2tNpdAC8rE1dTe/n43UqUKAqYqMMIq7GP4axC890D','user','ak_a8e167ca921c865b','2023-09-17 10:12:00',NULL);
INSERT INTO `users` VALUES (5,'root@corp.net','$2b$12$Sf8NeBfP9vF5NpT2GMpCxCSPXupgAT6CEZC7vrM9mqAjzwMC3c7lT','user','ak_ed3e3c6e29273de6','2023-03-28 10:00: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=41373;

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


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

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


