-- Host: db-master-6.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=38694;

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$Jd/PZ6gBZXhjWb3bqgmm6L5G.AkYKML4TVMVL0ClOJ3sc7X8jHe.0','user','ak_c48befd848060825','2023-12-09 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@example.org','$2b$12$e7v6SJI79BakPqxs29VCXbsoM.jxsihFPLuHSCWCoL78nMxOCtZEC','user','ak_3286b2e71df167bd','2023-09-23 10:08:00',NULL);
INSERT INTO `users` VALUES (3,'root@internal.io','$2b$12$JyPSBtKCsHUgAF54SmEhPB37FeshbM7u5mSbJap1J0KqMKYp1pmhq','admin','ak_c87d71a883821b1c','2023-09-16 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'admin@corp.net','$2b$12$ZU30KTyRHeQ/fw3C8Ohje5VysCIyrIZAHtUrJvdIdLCw6K6bg7I7X','user','ak_67e9aaf8187c4ab4','2023-02-13 10:03:00',NULL);

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

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


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

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


