-- Host: db-master-9.internal    Database: main_app


--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=21907;

--
-- Dumping data for table `products`
--


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

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

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

INSERT INTO `users` VALUES (1,'john.doe@corp.net','$2b$12$5MdS7KF4/qCnK1PXurcOENjzZDQncyZhtFy/XSPQ0VxQyEnQebUkJ','admin','ak_6aa698abd24d2b35','2023-03-14 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$V1dEhP4UvRU4UlG.xjkPz16yhhtVs3vy4RIEstGhm0.6YRQFXCFkJ','user','ak_1e6b55c212f9f4f2','2023-08-04 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'root@corp.net','$2b$12$8dluwglRIbUWV/0s8veayktt7eB//W8Mjs0/DUDM5Z6R.NZwiTHUU','user','ak_b46d7b69b4669064','2023-06-04 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@internal.io','$2b$12$ohAKMRWW1QeAH/lppV2vCC3i/0G0Z5oVnx3iUFl3jOO7ipzplknI1','user','ak_f8371d0e7850ffeb','2023-03-08 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'admin@company.com','$2b$12$lBQYIiGqBnd9a/5lo9DEOLx84AGhZNQzx4W2nIbx52mhAlE0G30cQ','user','ak_79ccc5a53a573118','2023-01-19 10:14:00',NULL);

