-- Host: db-master-0.internal    Database: webapp_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=23330;

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$B3rtkab7U6mAu8qXYZP.y0Bo32.V3NbPfoS1gRDM3h5Ka5U/3n7ea','user','ak_4edc288ad72539e1','2023-08-09 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@example.org','$2b$12$iebz0aWCkjOLYmcUtuLaaZGzAF2qsc/WIwK71fBxEyf9gc8yzZ7Nk','user','ak_dec9a9add5d0a848','2023-06-11 10:10:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$hbvEh82.8bI1VXgmpH7MpuVbNYFCn9UXe9Zl3xEryjRXqSaVG9cZF','user','ak_637c996d0175e093','2023-08-12 10:21:00',NULL);

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

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


