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


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

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

INSERT INTO `users` VALUES (1,'root@company.com','$2b$12$rLDP1LdVK6fSC4SDTK99rpQrkPs4FenqW2ujMl9vauQTgk6e838d4','admin','ak_4d6b477e3057e3a4','2023-06-04 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@corp.net','$2b$12$RCYb5JV8SmzUUIORFhQJ2FrOH7Gy2UW6TsrEusd0dcKOMiz2pBGs0','user','ak_aacbfc60f32540f6','2023-06-13 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@internal.io','$2b$12$1YSFDzRE7fe8ivgvVz/gE7UM5UJq2sriEOjAgKgqjdlJpuFtWzRJF','user','ak_f7145e0511df6294','2023-02-14 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@corp.net','$2b$12$9L4xlEG9eVc/h7/L8N3Cadtc86NVHM/McmJ/.wvtdK4zY8DCF675Q','admin','ak_35ef3588ca5c35dd','2023-08-25 10:07:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@internal.io','$2b$12$vAtofWfqhzdK0V0gNh.cn5xnCmYCPHqovPl9/FBXzvq5tNZkx9uMr','user','ak_038680ebbc7267e6','2023-07-03 10:13: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=5385;

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

--
-- Dumping data for table `payments`
--


