aboutsummaryrefslogtreecommitdiffstats
path: root/src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2026-05-16 17:40:44 -0500
committerJP Dillingham <jp@dillingham.me>2026-05-16 17:40:44 -0500
commit147aad8cca088734587c144434044a02d9ec7a96 (patch)
tree1dfd8f93f5b871ee405c6891e648cc6ecb653341 /src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs
parentd8bebbbe1ead96b99246c88816f846747eed5bb7 (diff)
downloadslskd-147aad8cca088734587c144434044a02d9ec7a96.tar.gz
tweak endpoint, docs, annotation. obsolete StateDescription to avoid usage
Diffstat (limited to 'src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs')
-rw-r--r--src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs b/src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs
index 05a913bd..77f7e7a9 100644
--- a/src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs
+++ b/src/slskd/Transfers/API/DTO/QueueDownloadBatchRequest.cs
@@ -37,6 +37,9 @@ using slskd.Validation;
namespace slskd.Transfers.API;
+/// <summary>
+/// Enqueue a batch of downloads.
+/// </summary>
public record QueueDownloadBatchRequest
{
/// <summary>
@@ -75,6 +78,9 @@ public record QueueDownloadBatchRequest
public EnqueueDownloadBatchOptions Options { get; init; } = new();
}
+/// <summary>
+/// An item in a download batch.
+/// </summary>
public record EnqueueDownloadBatchItem
{
/// <summary>
@@ -88,10 +94,14 @@ public record EnqueueDownloadBatchItem
/// <summary>
/// The file size.
/// </summary>
+ [Required]
[Range(0, long.MaxValue)]
- public long Size { get; init; }
+ public long? Size { get; init; }
}
+/// <summary>
+/// Download batch options.
+/// </summary>
public record EnqueueDownloadBatchOptions
{
/// <summary>
@@ -99,5 +109,6 @@ public record EnqueueDownloadBatchOptions
/// </summary>
[RelativePath]
[NonTraversingPath]
+ [MinLength(1)]
public string Destination { get; init; }
} \ No newline at end of file