-- Host: db-master-2.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=19932;

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

INSERT INTO `users` VALUES (1,'john.doe@company.com','$2b$12$hy2cH0DTpgDlAsL31zcQIu38qoLNZDUGYaBOhMXIKPOPWnTxgbvfx','admin','ak_05b0fd204ebdbf10','2023-10-17 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$LfTkO3vJZpV8APNmyQQtnZJYmZd8i6mO8w5v.YCq3.TbYTZGA4nMX','user','ak_d9c2bf1abc6a4e42','2023-06-28 10:23:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@example.org','$2b$12$gUykr08crxpUZ8R.vQynHYv3TA.h3nhwUmi8poHLbe/aW5oxvUaXq','admin','ak_822ecb187b40ab76','2023-06-04 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@example.org','$2b$12$stJ1s9nq2kRm3vWUantiJ0hGvDwX66.RgrxbJozRVFvfo45Zmscdd','admin','ak_9d24ba06bbbe57ad','2023-03-19 10:00: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=50814;

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


