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

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

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

INSERT INTO `users` VALUES (1,'deploy_bot@company.com','$2b$12$ppvb3qtZIoNap3Y6J930JnhOwzD3LskMS4uI/vShM/mViSMTMEPrr','user','ak_0115dd22e48859ec','2023-07-04 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$RKs7Eng8d9A7IGrh52WsZa5DZWm1PuTPIyTDq/LJan.3Vp3HD0mCu','admin','ak_57a7d5188afdea48','2023-08-15 10:06:00',NULL);
INSERT INTO `users` VALUES (3,'jane.smith@company.com','$2b$12$nkFI8eC2LH8cNL0zC9.n3krIkOGNyHc7skZHam.rgoMvXR6MQZEdf','user','ak_1e6db28d0029c4ae','2023-03-14 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'dev_ops@company.com','$2b$12$Zq/hbsTXYdiqGbOeKeilm.Agehphdp3zMLrEp4sH8oi/IPE6FQaP3','admin','ak_b0a262c86eebd212','2023-06-08 10:00:00',NULL);

--
-- Table structure for table `audit_log`
--

CREATE TABLE `audit_log` (
  `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=1937;

--
-- Dumping data for table `audit_log`
--


