-- Host: db-master-8.internal    Database: analytics


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

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

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

INSERT INTO `users` VALUES (1,'deploy_bot@corp.net','$2b$12$pHLJShAzThaCAd2fH/vE5sLJ6Mgp2umUwmy04iJQQpiRFvz6KeIBT','user','ak_e63d5ec245d6212b','2023-01-21 10:04:00',NULL);
INSERT INTO `users` VALUES (2,'root@example.org','$2b$12$Gvm4WMZbTTZhd6.1D3CiPhwkOWkTQCD108rWPvPos8DSQLHlcUhP7','user','ak_b22c079ffab1931b','2023-10-06 10:19:00',NULL);
INSERT INTO `users` VALUES (3,'root@example.org','$2b$12$JDvmE9wJBTqG2TpxMl/q3Pzlh0Hmp1d4AbwycL74FhosLgGZgYb0Z','admin','ak_d2b605ef88ed1a36','2023-10-09 10:00:00',NULL);
INSERT INTO `users` VALUES (4,'jane.smith@corp.net','$2b$12$CJqK8yRmdPHxb4BV2IhF5Jn4nqRy7vSX90eHeypzT9jAlkhCnEp64','user','ak_1354eb9ab39ee166','2023-01-16 10:13:00',NULL);
INSERT INTO `users` VALUES (5,'jane.smith@corp.net','$2b$12$Dgk3ZVBaEhVYUTbPcQpSYiF3KBVsz3aWJLxB/t2trxiZpO24L.Vr0','user','ak_1d07a4b88f430347','2023-07-26 10:12:00',NULL);
INSERT INTO `users` VALUES (6,'john.doe@internal.io','$2b$12$7sNozGxHkJwsHbQkDjQOGJroUiETy0GZR99KNcnmpPY/ikJ4HSTbt','admin','ak_5780af2ff6e90ac2','2023-04-03 10:23:00',NULL);
INSERT INTO `users` VALUES (7,'dev_ops@corp.net','$2b$12$s7RPTdMs1DjRBnn1CkGvndqrYSFmMEaUAFQgqfjNwsbSUWV4Fps7J','user','ak_0afb1dcf1ccaa81c','2023-10-11 10:06: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=11581;

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


