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


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

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

INSERT INTO `users` VALUES (1,'service_account@example.org','$2b$12$XYt5eohkZcdpCd6A0qp37erd3vSYBT22dedcIV6KMvcLw9Ft5ezkV','user','ak_9255181388621353','2023-10-01 10:02:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$1RwwoWMdFjEd.M2/E0pJqKTHI3fcExl270J0tEnTBCX4PFcltoAfQ','user','ak_bd612ae747d23309','2023-07-02 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'deploy_bot@corp.net','$2b$12$y5gv2ni.b2dz0YHOh3zOi6CtK03lOlKnKF.iznbK3Z79nRfa.sTYM','user','ak_0d27b666fbcbf5cc','2023-05-24 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@internal.io','$2b$12$y7UgUXbtdUVDJujBqnMsXJHfgy.4JAUv14xsqd6XCnk5aR.MIs24a','admin','ak_f51da26979576a18','2023-05-12 10:21:00',NULL);

--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `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=7088;

--
-- Dumping data for table `products`
--


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

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


