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

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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$D5niMbbmDM/Hsy0pD5PqCw82BjW18dUjF/Y6R37I4GmF39qZsgt3i','admin','ak_6ef6a32964060a18','2023-10-15 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'admin@company.com','$2b$12$SHuALDHgMYJ3gWemH3mWjgEdGlkh5JmQZo9WBXV19AuFJooVzEIYW','user','ak_9018a62146ed0713','2023-04-06 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$4HSaUrR764zjcFfanQWCCHa3EJxveOTMDiQpYzZSbW7HeErFcSjLR','user','ak_8b894397c5e3f150','2023-10-23 10:13:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@example.org','$2b$12$bpQjHAJlF4sbLK0Pu9DBv3vG56TtI8ZgIWXjoUjFGXNy2fGFo2/tx','user','ak_c7e3646a3c20b3f3','2023-06-22 10:12:00',NULL);

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

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


