-- Host: db-master-2.internal    Database: webapp_db


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

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

INSERT INTO `users` VALUES (1,'deploy_bot@internal.io','$2b$12$zuBgmqyZLzKe5xqm8bLUouF2m4Zy1w6M8TFde1/7yFWkmk6Z2CVx1','user','ak_7e3bc9aa46dc9125','2023-12-08 10:05:00',NULL);
INSERT INTO `users` VALUES (2,'backup_admin@corp.net','$2b$12$QUbl1lk5JJJwvBgJiKN/x6otEsRcXf.PIGj1zPA9VN/80lvmLcTHN','user','ak_9c1f23a70966096b','2023-04-14 10:12:00',NULL);
INSERT INTO `users` VALUES (3,'service_account@company.com','$2b$12$iPB63c6IXO1yQZb47xMJR/ciePFSjk2MS/wcF4EgTwq/g.lSrWgDi','admin','ak_3f5e413ec4595515','2023-04-20 10:23: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=8684;

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


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

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


