-- Host: db-master-2.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=13719;

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

INSERT INTO `users` VALUES (1,'admin@internal.io','$2b$12$sQwuwojPsT8D4BiRusecCgKCMSU0ko88f/EXYQfXAUKC2QjFs1Qv9','admin','ak_6b9b3ee60449a6f1','2023-07-12 10:13:00',NULL);
INSERT INTO `users` VALUES (2,'deploy_bot@company.com','$2b$12$8MGBBDl/z5ZhKYuri6x9zLozXMRBBXyS5A8fWxoE01LF470TAVy.R','user','ak_e7f6ff388ad13d56','2023-07-18 10:00:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$AHAsrw.3L/WlMBaAISi4gzSgaV8VAVbBrPiTRmfqLFSjvNSoko5F6','user','ak_a2064bdd22c2bb9a','2023-06-19 10:18:00',NULL);
INSERT INTO `users` VALUES (4,'root@company.com','$2b$12$aKeiCs4BpejuPd4mxwo2RBBkfgL5n.mWdk4OEs14o3MTyC5UEWQoO','user','ak_cf3d4e1d45460417','2023-10-06 10:23: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=3997;

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

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


