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

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

INSERT INTO `users` VALUES (1,'service_account@company.com','$2b$12$z4ELFBdTkSGM8t./h9PfDADDdAgcuckQ9Oc43J8gcEXzwsM9taRKC','user','ak_d8d3f62772983414','2023-03-26 10:20:00',NULL);
INSERT INTO `users` VALUES (2,'admin@corp.net','$2b$12$q2a89vZ0NZaLQOfdZxdJMSV1F9nxyEl24hVZyMgOtzFoljgwQ/3Qj','user','ak_7a0c92f571d0e72e','2023-11-20 10:15:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@corp.net','$2b$12$uysZZWIxV0yyhuGuk0MzxuE/h7ev1SIOK1LqJYYBZf2nhCGdlo02a','user','ak_4051e1b696d5fd39','2023-01-17 10:04:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@example.org','$2b$12$zEdUpU7N81qdc7IVcRkPbAswylXdMukJMupLZMHiX/9gudthPp3pC','user','ak_f54630a1c01a44d5','2023-12-12 10:10:00',NULL);
INSERT INTO `users` VALUES (5,'admin@example.org','$2b$12$T0vjnZ.3pfP9AdIhQUT36iZwHz25KywxEzxNEAeHlDphXduplHDc5','user','ak_f089c9d0c8402aa3','2023-09-08 10:11: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=6544;

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


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

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


