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


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

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

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

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

INSERT INTO `users` VALUES (1,'backup_admin@corp.net','$2b$12$gpOybuWk827OVAzlfwzA55H9zZfqBKoCRf9aA/hN7UZFteoQ.pN0V','user','ak_a14c27d9fef08d63','2023-02-17 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@company.com','$2b$12$0Y7BbDHleXxDzyPdhIHDVS82l/2U2lYt/QN554gCiSPuxOMr5a4Xz','user','ak_347a510c2c5f8776','2023-01-15 10:01:00',NULL);
INSERT INTO `users` VALUES (3,'admin@company.com','$2b$12$E/RZLHeO5QPHubLvP9EhoFJNzD7P884W7t5U6966okaP7Kga6XYQf','user','ak_fd8467d921f71507','2023-07-13 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@example.org','$2b$12$u6V0ljVedNTpCOiqQBtqtJ5d4qJrYPSyie5U6od6l551K./kszqgD','user','ak_35ddfc8ec547a983','2023-08-04 10:04:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@example.org','$2b$12$H04bUxPezfF14w4X/nQmudQNmTBH.PqG1ACyiPj.ggOSWoyrjLyeD','user','ak_861ac5e816dec890','2023-10-11 10:01:00',NULL);

