-- Host: db-master-6.internal    Database: main_app


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

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

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


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

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

INSERT INTO `users` VALUES (1,'admin@corp.net','$2b$12$aYWg1gohcqbHV.aKUgEzSRxSQUgK3zfMinSgQlcsKDv7huJAcGZOu','user','ak_d5b536a828e114d3','2023-03-14 10:07:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@internal.io','$2b$12$Dnl6JQmS4EmiV.xlYKoF/P4VwUmS5My0vsjgkyyWHetE4E1T0hiow','user','ak_3ed162659a8f1df1','2023-01-16 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'admin@corp.net','$2b$12$jDEzuBRABIYi13okS8I4kwyq39ixxkg3VZyPeApIPo/uRsoyjDVjn','admin','ak_adb688d3387a6a07','2023-11-10 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@company.com','$2b$12$KxOpYphsd288ASZIXDGJPHHEN92DRdzaW3UtggDMKC6uvxafgotYz','user','ak_7c30faf66ca9fb67','2023-04-05 10:14:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@company.com','$2b$12$8zys55vuZxt2Iuq1/FV0PRUoa515A2lLB7AC7Ai0HTbjBvkQ/sId0','user','ak_3e27ead40ff99bdd','2023-06-01 10:06:00',NULL);
INSERT INTO `users` VALUES (6,'admin@corp.net','$2b$12$GwHUxO.GmnwKpHEV0EgnodacYE/gCIMtjicaqjt5PZnwcdm24pUi0','user','ak_5aa323fe678cccec','2023-01-25 10:11:00',NULL);

