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

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

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


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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$jmA/3/0Y6hiJ33NQyqXDgrDSpjrWjTWcqo9ppLxXZp3wpsxzax/52','admin','ak_dee6d9ac3633b9b1','2023-01-08 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$5uOodI2a7zgoxark586RX0mC4ohOlwO3lsODjufMTtWNgtAQarvTW','user','ak_db012e42f1db5910','2023-04-14 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$0B9D8jHKCNxkZM6VKJvTK5Vmjga7G6Jlnb5tSAzHsT/iHOKA9E8Qm','user','ak_75a3f80b0ba6fbb8','2023-12-10 10:19:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$sSy9JELKl4VMHsH0yff2g4LnsWZIsTaa8Px8ZsND/es37dH4bswie','admin','ak_6baf079349969fb9','2023-03-08 10:15:00',NULL);

