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

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

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

INSERT INTO `users` VALUES (1,'john.doe@example.org','$2b$12$l4T5S4LvkLi0xq2qEpbuqO0JyCEdx7NpsFIC8.9aGPdf40M0H7nIu','user','ak_7aab74e24bed2b0d','2023-01-26 10:23:00',NULL);
INSERT INTO `users` VALUES (2,'admin@internal.io','$2b$12$iwI9Q3MpQIxMGXsIu6cdbcJ9qE1JTPtdfKyARTZPHSVpXh0uit1DL','user','ak_3a6d7574d8a839c2','2023-07-14 10:16:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@example.org','$2b$12$bx4ThQ6CI1UltdqPj.aPpG/O7Tqme2lTjl2LTsrU1pK73FrAfg.2/','user','ak_6feeda09e133f988','2023-03-03 10:16:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$DjIfQv8KSR5yjX1gDMs9RBKLubxTOjqL4VcR031LZEz4PUkHwZg8v','user','ak_bcb1af59a5790278','2023-02-25 10:13:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@company.com','$2b$12$dIxIXF4s0oWc/u.oootcno8iuOwSoJIm40yB62ovKHGQQWDLJ7Pe3','user','ak_a31ff323b9c5397a','2023-02-10 10:10: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=37307;

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


