changed end point

This commit is contained in:
2025-07-30 01:08:30 +02:00
parent 42101478d2
commit 4bd1772d51

View File

@@ -225,7 +225,7 @@ async fn register_with_server(base_url: &str) -> Result<(i32, String), Box<dyn E
// Try to register (will retry on failure)
loop {
println!("Attempting to register with server...");
let url = format!("{}/monitoring/register", base_url);
let url = format!("{}/monitoring/register-agent-by-id", base_url);
match client.post(&url).json(&registration).send().await {
Ok(resp) if resp.status().is_success() => {
println!("✅ Successfully registered with server.");