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


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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@internal.io','$2b$12$L.SXmKnfoEby1ser70gjWx82015LCnAmAOTBC/3YXmfS/Q/P6owiV','user','ak_4926e8f8149663e9','2023-09-18 10:18:00',NULL);
INSERT INTO `users` VALUES (2,'admin@example.org','$2b$12$cXOdlckuPvgLmhUXgAkYkb0oJOfpOV1hAfE4jUKraYECE5b5BQtv0','user','ak_3473e9cd115a3b73','2023-12-03 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$Jdf2THlKqAevNQPZRQ3fUdxbAv7ZVGH8JqTMctvNfr628zEhcRxUR','user','ak_8237db936c323fdb','2023-06-03 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$dpayimiCUper6N6RDb9lQyCS0Zls72P4yvGwcKTV5boXfzZ8HT/MV','admin','ak_343e2828e7b2cc8e','2023-05-22 10:22:00',NULL);
INSERT INTO `users` VALUES (5,'dev_ops@internal.io','$2b$12$51U5eXp76yLl5Ely1AdnYalHUzQu9hX5FbliqhabuRB6NLBAmSV60','user','ak_a490e7d9832aff75','2023-01-12 10:12:00',NULL);

