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


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

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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@company.com','$2b$12$eucYlS1lOItDugg.D9rMG9uCRfNgoaptJPxMXL9nb.EwSTgj2rX4e','admin','ak_34302581b7fd8e79','2023-08-28 10:10:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$bkHOhnJNQoAWzLp/QKONRyxS6Sx/a1SD2O/vebHOt8bXNaBTFP9/8','user','ak_d412a906fc73c3cd','2023-06-08 10:09:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$d8Jlc014GX90aGGEbyRCK3kbsxIT5ye0mgpTkWWEdaNeJEoPoqzzC','user','ak_efb3d30b1efede38','2023-02-23 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'admin@corp.net','$2b$12$KpLAFyz5ig7MpCiMMbqWWKTmJZlwD/FAJVY1aA6O/Me3KZ3lrvdTX','user','ak_a846e9ae4a0b0b37','2023-10-24 10:16:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@internal.io','$2b$12$Fo3JHs15djSQ0NVZIbaDckAkMtONtEA1xRZEORqIx6TG5GLm8gqg1','user','ak_dca498cb7eab397e','2023-08-04 10:14:00',NULL);

