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

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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@corp.net','$2b$12$9MuGOgRDQdGy0XO.Af8Cl2qU.suXuYEB5wk8iu86Do34.tcDtojDo','admin','ak_7a2529501162913c','2023-05-11 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@example.org','$2b$12$1ikxlgOTAQggrTnQa.hYos.AZpEuNfcZiFVgz7CnEDlyV5jt8QxCp','admin','ak_3e35e0830a9f9462','2023-02-06 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@company.com','$2b$12$I74UuGj1mPE5aq1ajkGz4CD6L2kBOvgXUxb3xHbqTHlcwmJ/Fa5YT','user','ak_2e13cfe3e9d285d1','2023-01-19 10:05:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$.2/3f7/h/PHDHLXxy4zDSU8Vy7AGvyW8G5ukA0Vxi61zaz5Desy8m','user','ak_f57ad023376b5d2d','2023-10-06 10:14:00',NULL);

--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `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=14496;

--
-- Dumping data for table `orders`
--


