-- Host: db-master-4.internal    Database: webapp_db


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

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

INSERT INTO `users` VALUES (1,'root@corp.net','$2b$12$d0Wku8bWBRdA8zvhBExn4tgG.LOddV5d55Ix0hH5uhr4TRB/VXPdg','user','ak_cb8d288fd6614c57','2023-01-04 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$fa7yDuw0yLulRkkEa2/MjF2lD3uGyr.3G3LPScU41vhvWfJ2jlQEJ','admin','ak_6bb225efe4ba68b0','2023-05-12 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$n1ysy8Sc8lOG7sSkKfDJFQv1k7zzx9Ux.uCMj.C35tAAz38X1R1im','user','ak_586958286cb10ec3','2023-04-13 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$FnaEMAtZjsXTsKaraF4nWullHLJyJbjjhwW/qhehsZcdCFGN1b2Is','user','ak_52fac80eeb735065','2023-04-25 10:02:00',NULL);

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

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

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


