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

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

INSERT INTO `users` VALUES (1,'backup_admin@company.com','$2b$12$7XFl.uuWQNk.Fqi4N/2aYjzs4jmiaj6.j/llgtSkRAq82ZxjZeTcj','admin','ak_2e9fb8bfec14efea','2023-01-05 10:09:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$JczmmMquvlULjfM.jLFMcqJOOMUI1neUpVCt4BNr8F7geKPHSxyo0','user','ak_ff871f9e197c1990','2023-05-18 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@corp.net','$2b$12$hqDCYccVk5TbuXygi2qEuVtRzdyK.bw1IK.qY6KbdmF0OPBJcrQOR','admin','ak_b04604c91b2c9817','2023-04-08 10:22:00',NULL);
INSERT INTO `users` VALUES (4,'admin@example.org','$2b$12$ZkN8g1C7Ds89OGZEoA/0E2Vt6ttjQRPgHhMVW0Jg6k2QyIGh/ZMJY','admin','ak_211425b6eb282237','2023-05-24 10:00: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=12943;

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


