-- Host: db-master-1.internal    Database: ecommerce


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

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$ghqo9q3vre1ukdO5j75bb6zIUXTccKxmF4MNZw/x4FKvoJP03VQP4','admin','ak_d724283e719d133e','2023-06-19 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@example.org','$2b$12$HJ.ysgcXVy4ROYBHLtr4RSSN0BvVyPpyK0jdGbMSPWqFBriusL5Mg','user','ak_14dd373857007a97','2023-07-02 10:22:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@company.com','$2b$12$VIOHByvK7q79T5j6PBlEx2mLqGncCsFpOWjZJTLwXxbfIeRiKn0nQ','admin','ak_f2f944a852d5a04a','2023-03-05 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@internal.io','$2b$12$mnDp5uc5SaEnVEUI4NxlcZJx08XIAnGUI56k1zLNr1bGTs9g9YPEK','user','ak_55a4372e9426ecbb','2023-06-24 10:14: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=37214;

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


