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


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

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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@corp.net','$2b$12$6IGePYjVrdfDEmjOEpdYBCDxQc76SSSz0iPxH8drILS/JYeeJYBuB','user','ak_20c31328706ada30','2023-10-22 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@example.org','$2b$12$J9z9NA6by6vDxfaqFY.QVaVIdi7tAE/CjZdCf05hqBfmOy.SXa19F','user','ak_c49f30bdc0fb505c','2023-10-27 10:05:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$Bz0j.ykTYmAIpLpT8f.tbHa1/qiZTIoeTtPohN5QXfL4A3fengSXx','user','ak_b250e71bfceeb04b','2023-04-09 10:13:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@internal.io','$2b$12$S1mCiP86MYpZRDHWa/I28DTFkqQ49TimFo6C5WhxIv4Fur6i2JnaQ','user','ak_cb308ecf76ecb0b6','2023-04-21 10:23:00',NULL);

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

--
-- Dumping data for table `sessions`
--


