33 lines
1 KiB
C#
33 lines
1 KiB
C#
using System.Text.Json.Serialization;
|
|
|
|
namespace Clawdforge.Models;
|
|
|
|
/// <summary>
|
|
/// Response body from <c>POST /files</c>.
|
|
/// </summary>
|
|
/// <remarks>
|
|
/// The class is named <c>FileToken</c> for consistency with the other SDKs.
|
|
/// The actual opaque token string is on <see cref="Token"/>; the property
|
|
/// can't share the type's name in C#.
|
|
/// </remarks>
|
|
public sealed class FileToken
|
|
{
|
|
/// <summary>
|
|
/// The opaque file token (prefix <c>ff_</c>). Pass via
|
|
/// <see cref="RunRequest.Files"/> on subsequent <c>/run</c> calls.
|
|
/// Wire field: <c>file_token</c>.
|
|
/// </summary>
|
|
[JsonPropertyName("file_token")]
|
|
public string Token { get; init; } = string.Empty;
|
|
|
|
/// <summary>
|
|
/// TTL the server registered (clamped to <c>60..86400</c>).
|
|
/// Wire field: <c>ttl_secs</c>.
|
|
/// </summary>
|
|
[JsonPropertyName("ttl_secs")]
|
|
public int TtlSecs { get; init; }
|
|
|
|
/// <summary>Bytes written to the server's staging dir.</summary>
|
|
[JsonPropertyName("size")]
|
|
public long Size { get; init; }
|
|
}
|