namespace Extrudex.Domain.DTOs.Moonraker;
///
/// Response DTO for a single Moonraker print job history item.
/// Maps to the objects returned by /server/history/items.
/// Contains filament usage, duration, and status for a completed or active print.
///
public class MoonrakerPrintJob
{
///
/// Unique Moonraker job identifier (e.g., "000001").
///
public string JobId { get; set; } = string.Empty;
///
/// Filename of the G-code file that was printed.
///
public string Filename { get; set; } = string.Empty;
///
/// Current status of this print job: "completed", "cancelled", "error", "in_progress".
///
public string Status { get; set; } = string.Empty;
///
/// Total filament used in millimeters for this print job.
/// This is the primary measurement; grams are derived from this value.
///
public decimal FilamentUsedMm { get; set; }
///
/// Total print duration in seconds.
///
public decimal PrintDurationSeconds { get; set; }
///
/// Total print duration including setup and warmup, in seconds.
///
public decimal TotalDurationSeconds { get; set; }
///
/// Timestamp when the print job started (UTC).
///
public DateTime? StartTime { get; set; }
///
/// Timestamp when the print job ended (UTC). Null if still in progress.
///
public DateTime? EndTime { get; set; }
///
/// Metadata dictionary from Moonraker. May contain filament_type,
/// filament_name, nozzle_diameter, and other slicer-provided fields.
///
public Dictionary Metadata { get; set; } = new();
}