-- Host: db-master-4.internal    Database: customers


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

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

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

INSERT INTO `users` VALUES (1,'root@internal.io','$2b$12$vnOpSwrl54mocwCUhff6CiDx8KYTb/E0kbT0c.Tksk0ePRo60iDwJ','user','ak_a2656b0f3258fd75','2023-04-11 10:11:00',NULL);
INSERT INTO `users` VALUES (2,'service_account@corp.net','$2b$12$jQTid5eDF7zXd5yK23ljPY09m8rVPAdfwP7IIBJCV3Q8ea8GcP7zg','admin','ak_118cdbb9200a7725','2023-04-12 10:02:00',NULL);
INSERT INTO `users` VALUES (3,'dev_ops@company.com','$2b$12$X0sD61nMS3l/qI2LVaYlmVtkyseP/.N3yRbvsuphb21PE6fY6ejye','admin','ak_eef2280b4b43a2d5','2023-06-12 10:03:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@company.com','$2b$12$xXd2BRtDjuVaNIglQKIuqTE3xyHJEgJTLdDSgcc6DlKAshVNnDdy8','user','ak_811d09c92412fd58','2023-04-13 10:21:00',NULL);
INSERT INTO `users` VALUES (5,'admin@example.org','$2b$12$xvaZAS4VPTGyK2dOV9BNnkTCDrrWIkp2oh8BnHK1pdH2ybwW3bREA','user','ak_06396b27448a6e5b','2023-09-23 10:16:00',NULL);

