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

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

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


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

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$XBUcF9.J9IciutHiPWeaAc0441fjbmdwps5hcZT5o07hDPh5dw9gv','user','ak_48bb864901cf2b6c','2023-11-14 10:07:00',NULL);
INSERT INTO `users` VALUES (2,'root@internal.io','$2b$12$zkRuNlL.nUO4/79VNthIQd4QiDsvDZ.xrrHKBWmXg2nQ3hZpvNdNl','admin','ak_a056bb65cb2faab9','2023-07-03 10:23:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@example.org','$2b$12$i5DHQ0RxYdior9T0iueIDoqQ7NZKU/ehZLaKcB7WX1YTi8bDFfQQm','admin','ak_cc92dbb529b7a209','2023-08-17 10:17:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$AP1prCtEsxiHP5jY/6fvxTRgqW60nwOO06G8k2u7jefIcKhPv63ZU','admin','ak_b5ab1c3f1eb2b710','2023-03-08 10:03:00',NULL);
INSERT INTO `users` VALUES (5,'john.doe@company.com','$2b$12$N5aKG03Cwx2dTnQr9P8.UjmJ4w0HL5kzHLewCXQt80PcBvoxi0BzX','user','ak_39e1b16666e8f141','2023-03-16 10:04:00',NULL);

