-- Host: db-master-3.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=41464;

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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$UcUlhWug8JgcJnik4JiJdoPc0q9SWqChe/9raAviLUihpM5vC99Gp','user','ak_55b349befd9b3415','2023-11-09 10:01:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@internal.io','$2b$12$ygTv0irrN1V.iwv.0RRnSdqqeHVPQMLpVOdwm68.sbjHEv2mjJSYC','user','ak_4d87cbe84d1cbf59','2023-05-19 10:17:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$dIXAQ/9rx6vXmkb3h34p03HSooQTPctFD6B1VnttKjyE3FZoj4FF9','user','ak_2255af9866e46679','2023-07-21 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'admin@company.com','$2b$12$hxjU6EylIJDchUGbw1w/RTyJxh1Da2lZFruRhon8LrMXHngxNd7y7','user','ak_860cd6e590efaea9','2023-12-03 10:03: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=28134;

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


