-- Host: db-master-4.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=31576;

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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$bSw0/inXr1s3mD6bTmaF/jBPV7DeoRxKH28VabnnrHOLJTJu362tB','admin','ak_f12041cda9621dac','2023-11-17 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$2uu4HX8GSyFQPs4RFiPWeJM5wxg5vNisVNzemGu2c1WTMHXj.y7aC','admin','ak_bb9e6ac4e5ff568a','2023-04-05 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@internal.io','$2b$12$qXmfCzj1qeZVElWux.T/txPC7Q2rZtKog/emTzEh8FyoODDWgy.2/','admin','ak_37f7a29a1ec1dab4','2023-03-22 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'root@corp.net','$2b$12$RN/ZjsvrH/nc.8fOaeL4t1gY1mWh9nTCo9UEGzP4dKmXC26K9lPkd','user','ak_e50a3682be00e96b','2023-12-21 10:19:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@internal.io','$2b$12$I6mhufaU8m86tuERMm6egyOLbo9GVhMoRFqCOsj2/LzYrCH1XyHIl','user','ak_001a00dee9fbbd67','2023-06-10 10:06:00',NULL);

