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


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `data` text,
  `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=45058;

--
-- Dumping data for table `sessions`
--


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

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

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$Ixcnun5NiOj1/px4rEWmu7cwo5W8w2k4gM/hzjir.t7k4XqolsiGZ','user','ak_047774ddaf4e3fb1','2023-10-25 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@corp.net','$2b$12$O6vtEv2H2kOAC4kjFNa3cJ0iOvaWK521mRILVs/kQyM9Zepkl7NlU','user','ak_a69a5702b3959fbc','2023-07-22 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$pcRmECHjNjzUoyx5WTs.so8Uq5EMnWkmj0Wo24x2t6lgpLMjKd4oS','user','ak_3a6a3d0805ba17e2','2023-08-09 10:08:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$on8LIEF3KQfHXnHSODhYgtf6RudgiTKQwX0ZIXh.NLSYtOXRnsY1E','user','ak_16dc89ce9baa3c07','2023-01-28 10:07:00',NULL);

