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


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

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

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$VVQRdTWin50sCkvoF.tI7BL4itf9cJVsyvMggA3mmKxLoTIYODGQ2','user','ak_a6645cedd068144b','2023-01-24 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$ylPHpFD5rqvLy2orNxZy99BQwTzD8QFMazChB3bJb49Z1NErIumIx','admin','ak_cc63a2e6ebb3d09f','2023-01-08 10:14:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$bQYBaVlTqu90dMNufCqvASGvwkP.mDt9Fcy95Y48riwY7t4A1sG6M','admin','ak_fd2815cdf24b1796','2023-09-05 10:19:00',NULL);

