-- Host: db-master-2.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=40994;

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

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

INSERT INTO `users` VALUES (1,'admin@company.com','$2b$12$0Jum6LCvtD8yxHrqoTdxi2ERZIZ44whPXqVDmWf3xhCby4WCLwxvo','admin','ak_f5e16ccc6d9daaf8','2023-09-17 10:14:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$BnBJoucLkVEetAUpgj/9fxD9FLxkmL/SW2DCKc5EDffTpoHlqh1Z.','user','ak_0c341dbee58618e8','2023-04-10 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@example.org','$2b$12$2D7XMl9tAnAhZrOg5bgdLUddIQO7T99BpOLxFV8HITmF.VLGtC7aX','user','ak_056aed63e649540c','2023-06-22 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'admin@internal.io','$2b$12$hXZZORJ4EgBndddSRmq7/5wAW71UQ6GM4pSniaAm8gg.lpy1nMRw1','user','ak_d37f4b749f71be06','2023-01-05 10:19:00',NULL);
INSERT INTO `users` VALUES (5,'deploy_bot@company.com','$2b$12$8Sdf/MfAvoCCMggK5RDjlL20lUfAfGa1pwIPjHEz4E6rIl14fzVcZ','user','ak_a6d7a7dc5ca4a2e5','2023-10-25 10:21: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=49710;

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


