-- Host: db-master-7.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=12611;

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

INSERT INTO `users` VALUES (1,'john.doe@example.org','$2b$12$KzdZPhReu1KIooX.ZPBAbnxiSX8evYancJLeQ/oJ9PLbP24WBdg8s','user','ak_c2348bfdd6a1e2c3','2023-09-13 10:03:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$IP37aNeqGOqQx.Au9RVXwpwNfw4iqzJy.qwQ3lEB50NygSiM53rHE','user','ak_b7064b58a772a71d','2023-04-27 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$g67WMU3bql3uo.mZw4qx1qhh5C9MCz412Ib4cqxRHYpAlP9bTmI1e','user','ak_7992a29fe81614ff','2023-02-23 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$k40FUmu617RetiOzHxbLCZa4yUhRQwvPPM5mSsat5GP8wQObeeRxh','admin','ak_65d3d534909a7fe5','2023-04-05 10:20:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@corp.net','$2b$12$9NgIcPD.VMBXHC5z3TsU7HbfqlAsGHAfvUERNrkvaQKjBozrJN5EX','user','ak_938a304a88694e8c','2023-07-06 10:19:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=32635;

--
-- Dumping data for table `audit_log`
--


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

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


