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

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

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

INSERT INTO `users` VALUES (1,'deploy_bot@internal.io','$2b$12$7Fi88FrZZyKUsktj3eMvx.lFYXCn.ZwUEqdwZ4GgM9Y.SNLI/tXgK','admin','ak_127d24f534f409e6','2023-07-09 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$hNUYS3kDUtvJQCWi0pSvllytHFpstrR/Qwe9BKcm7EL5ij6gdGOeD','user','ak_51ea2ad2e7f5e98f','2023-01-19 10:20:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@internal.io','$2b$12$pa/XaIappe0YyRRjVfxqlg.Tws7Zwv6uK.kEaB8QFdTf3VpcW2Zr4','user','ak_0f0c39eca4aa494a','2023-05-17 10:09:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$2oebzu4KNytUxbottZE9VdPPTVG5n6veA1nvt1x4XGkydr0GO.Fcz','user','ak_9d8ce88142bd7165','2023-09-03 10:05: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=19076;

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


