-- Host: db-master-9.internal    Database: main_app


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

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

INSERT INTO `users` VALUES (1,'admin@example.org','$2b$12$/NYvG3yMfuNsjHmDoDD6misoypCZpufyQ2JLe3mtC4QYajpeSQAae','user','ak_48edd540f73a1dd7','2023-01-14 10:21:00',NULL);
INSERT INTO `users` VALUES (2,'john.doe@internal.io','$2b$12$aRZ2DCCqCHIF5c0SdUiqaTdocp6ZahENpyYA4bHMK1T2VNUQqJOo5','user','ak_2ec12cfdcc37d1f9','2023-01-19 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'backup_admin@company.com','$2b$12$C4nycfN/.LFYX4wkk3WquJ.FBvEhXZGmQgaAm7i3tc/gvxu6KUUgV','user','ak_1d077d471d9a08fb','2023-10-12 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@corp.net','$2b$12$6VEPzevDmX4ueZTobQrj34aEeArIgp4cpKD.3DxRDsH5OwdD0ppxd','user','ak_e28218148605a343','2023-02-26 10:21:00',NULL);

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

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


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

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


