-- Host: db-master-5.internal    Database: main_app


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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$i4uqGLid.tcM97TsDnBAlt9ZJhY3VeKRToFtKET3TZ4MkFRWq4f1U','admin','ak_d9fcf65a2d9e108c','2023-10-03 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'root@internal.io','$2b$12$.c6qJ3vcSmLLeNLJYWyAZJiJJK6o2cEbF2DLKhUEBMJ15OBySV/.E','admin','ak_241d040ef3822d0f','2023-07-17 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@example.org','$2b$12$gBDsDD7nJz3QvFEbmiOTybPmB6UXMDtQr50cGDONPT2fSbq6IfoxS','admin','ak_b75e8873727efcf1','2023-01-27 10:06:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@company.com','$2b$12$oaKDJWDykpDIJM0GJN2Te87aHK4Kqck.St/96nBtRwc.elFIfQ.pX','admin','ak_a459e254a00e87e9','2023-06-22 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@company.com','$2b$12$AUX1TzfpSuNZ8BsniAQYrPakufMRiVJGm8dIUo4Zc3nQoatrjXAya','user','ak_a5c822e87ad6e9f3','2023-11-22 10:03: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=36664;

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

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


