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


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

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


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

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

INSERT INTO `users` VALUES (1,'deploy_bot@corp.net','$2b$12$z4qjA4FCaBr01sEX8frYc7Qp3HGoGollmbs7mu7rWQvUiTGFXC3vi','admin','ak_f0b66bc51f8c621a','2023-11-24 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@company.com','$2b$12$CEJP6RSSkYNnBsCYCnyvKh17e3t5/GbCurCX6HvabRGGY2O2jehas','user','ak_c2f2254914534632','2023-01-08 10:23:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$1iOU5WhPjTKjj4.WhcPm0GRnaXjOIhurZBFIpAsecvgPS4ERTOGQN','admin','ak_3a9f1bedb7ee5eaa','2023-07-21 10:11:00',NULL);
INSERT INTO `users` VALUES (4,'john.doe@corp.net','$2b$12$dos8WByqZd4Ox.1mcAb7a2Q6Radx.xyi3V4VffhXB/CDMQUFdULev','user','ak_967d8f4e83daa136','2023-12-22 10:22: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=18504;

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


