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

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

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$HOHUmzxVPQzlHAHQ48C1T5Tl4SUzZpQhgCdQgmWJb7DQOlqPY1JAi','user','ak_a7ba5fe1cad69a6c','2023-09-28 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$/0fwblzY/68zR2F9/GrpMWwRIwDuu4rOPC7Pu5CnZA0Y3vgJTPKWj','user','ak_c08377a9a153e436','2023-06-19 10:04:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@example.org','$2b$12$AI4Hkxo5WRU1H8V5sIVsi.cV1eMBzMwPV71/o0pqsa/LanRclVrhS','user','ak_915fe00810e63cff','2023-12-04 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@example.org','$2b$12$7Tk6RW29aynNG7AGJauqgqADgXcqcmtJdHRO3WSEQDqinPeXD67O1','admin','ak_c8d0b01eb822362f','2023-07-07 10:18: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=45755;

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


