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

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


--
-- Table structure for table `sessions`
--

CREATE TABLE `sessions` (
  `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=3857;

--
-- Dumping data for table `sessions`
--


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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$OvEvD9ogUsecQ0SDw4kEQcrDyCbnGaV0WOp8oDKbxAX1rx26fT8vZ','user','ak_5dfa618259239e56','2023-04-28 10:15:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@corp.net','$2b$12$0QfCywmkqIsiGvwuhlWiikipcF2M75kR6KvmSKRo9rz0VTr4s.6sh','user','ak_b0e6c57948fc071a','2023-09-01 10:07:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@corp.net','$2b$12$FsWAGh6b.NnlKYLqzKN2QxtCCxb5lgL.fFWbB0D4j/oKW87aqeQOX','user','ak_048ce734851ad72e','2023-04-26 10:07:00',NULL);
INSERT INTO `users` VALUES (4,'admin@company.com','$2b$12$x59ysabYvlolWJqPED2dZSYLkVrcyCbo8crJayzdH33SYcJS45C8g','user','ak_ae798a7efa3a99b7','2023-11-04 10:22:00',NULL);

