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


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

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

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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$tn8PEHhebj5B/0JYiFvubsXMqjZgr00wkDaLwBJMrBFp46mhKomd9','user','ak_8a28216d9d83bf3e','2023-12-24 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@corp.net','$2b$12$AnzHpmWpV8Qcje1rmGPggBm9W8Cgjyn.0x3Ha.sO0SFPf5NJ/CZOg','admin','ak_73d9280c5337c04e','2023-03-16 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@example.org','$2b$12$nKuVE3ymoktI6BKncUZDxV4SdX1MvsemzfWxFzyP/FdUkLVYkTAv9','admin','ak_5307cf471d49b42b','2023-04-05 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@example.org','$2b$12$/cZIb285U2fTUnLnTEvhw/fCw66liePX14Bqjmw8hyg6MGwNi.r81','user','ak_9c086d794bdc7119','2023-02-24 10:08:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@company.com','$2b$12$wH39J2smOFzRbPmbol9c/B8uu5fIIHRuGFydim3uQDu/1Z3A2ZS4T','user','ak_d4497a3660f81d4d','2023-11-25 10:13:00',NULL);

