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

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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$Ir6RIMNbxyMh91fuDeotqrNHHNe2D4t868Fl4hUO3hFbXbVj5YMQQ','user','ak_38fe65b0bdf6a5b2','2023-08-08 10:06:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@example.org','$2b$12$QggYdOrLYIoZTvycWLTaZUmFIe55KegH./d47G6pN0MaYPciRARue','user','ak_1f2ad2952f855792','2023-06-16 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$HLPcubYL9G85hQzWQVTMeD2bgh6an0o/9OPnb46PP2F9YTm1C2nnt','user','ak_6d0e1f18c481b68a','2023-07-06 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$LuAsiwCSkNyfsWfY/ZsWjoEKGgqfs2DElXsIxqEiZLBB0YvCUUUZG','admin','ak_21203139d56df035','2023-08-09 10:15:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@corp.net','$2b$12$noO56u440DHaAu/v7zXIS0zsc2EmVPArXm2uXXhZPsD3w1O/vPy5/','user','ak_58f6cb7191431a91','2023-07-28 10:13:00',NULL);
INSERT INTO `users` VALUES (6,'deploy_bot@corp.net','$2b$12$atI9Uf7KivBS/FiYVKEbgw2fAcTphaE2DVpgBkwsNY7lLQ49bvDin','user','ak_8da94b0ac1eec664','2023-09-24 10:23: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=19535;

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


