-- Host: db-master-9.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=48555;

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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$5kFLeO.4Ds2CCCQDEZJIfamlECBGPSl5JbYINFWJzb3U0UP7vNGVd','user','ak_208f83277d966754','2023-08-17 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@example.org','$2b$12$9jvwRubG1VSN6ZLE6BFJ.rfNmJf2hA6Kcut0Uloo3dUm9ncaxRzAp','user','ak_78c9badb22ba66ce','2023-05-27 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$IrDS5GScr2qXIhjcCQ8EID.ylV.g.l78Orqe1oSd3cARRNBXYLs6N','admin','ak_bdaa8f09edd9ca11','2023-05-04 10:04:00',NULL);

