-- Host: db-master-9.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=14313;

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


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

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

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

INSERT INTO `users` VALUES (1,'root@example.org','$2b$12$FNqjG89vj/NpQofjgzbPxqo/BkqLWOQId5QHnKUxOf/yalXejgV2c','user','ak_98db0968777b9a79','2023-07-27 10:14:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@example.org','$2b$12$r84vThawooDvzpHp0Xiqqd1WLp7ozEkPI1qvKJljOHhXiHtQLnCsV','user','ak_423503d06a4cc5b9','2023-05-05 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@internal.io','$2b$12$yaN4WtvfUPxjGcbSzPkbb7moSq9vsXoj7UBIhSCC/wnpUxTata1Mw','user','ak_d7c6b3c5a13e22c5','2023-03-07 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'deploy_bot@example.org','$2b$12$nc5bLO1Pi8hiJVDGtVblBRTO18umHWhieHblNa3cqeaKHqlXtE9eq','user','ak_a9da840cf908d5c9','2023-02-12 10:22:00',NULL);
INSERT INTO `users` VALUES (5,'backup_admin@internal.io','$2b$12$CK5IKN.cchI4kq4KNz3uVHJ72CroSbENO.kTyZkNeJWH84mBT4.0o','user','ak_f3e89848bc84523a','2023-02-26 10:13:00',NULL);

