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

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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$KCQuKBHs/xDtltEIzfJjKXG11/RbBZyCixhRHqtuPq22NmT08nTpe','user','ak_e071c1679b1b8fe7','2023-07-25 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$xMd979hqZwAGV.NpGtnT37.yAGz4x/2HGYSoReeTV5Oh9xm8K1Bmq','user','ak_795c44e95b142e93','2023-07-19 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@example.org','$2b$12$dkCfJQHN2OxBoNaZUexZVvzFjfT/eSziZRTZ1Ba9W5ZheoOOs1xZ0','admin','ak_4637ced6ca8d5e4d','2023-09-21 10:04:00',NULL);

