Skip to content

RunQuery

Namespace AgentPrism · Assembly AgentPrism.Abstractions.dll

Query used to filter the run list.

public sealed record RunQuery : IEquatable<RunQuery>

objectRunQuery

IEquatable<RunQuery>

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

public RunQuery()

Gets the agent whose runs are returned.

public string? AgentName { get; init; }

string?

Gets the error type (RunError.Type) whose runs are returned. null includes every error type.

public string? ErrorType { get; init; }

string?

Gets the kind whose runs are returned. null includes every kind.

public RunKind? Kind { get; init; }

RunKind?

Judge runs are RunKind.Eval and do not appear in the default list (see IRunStore.GetStatisticsAsync); to see their cost, call GET /api/runs?kind=Eval.

Gets the label a returned run must carry, or null to apply no label filter.

public string? LabelKey { get; init; }

string?

The filter matches a key AND a value together: asking for team=payments must not also return team=billing. Give RunQuery.LabelValue alongside it; a key on its own matches any value of that key.

Gets the value RunQuery.LabelKey must have. null matches any value of that key.

public string? LabelValue { get; init; }

string?

The field is ignored when RunQuery.LabelKey is null: a value with no key names no dimension, and silently returning an empty list is hard to debug.

Gets whether only root runs are returned. Defaults to true.

public bool OnlyRootRuns { get; init; }

bool

The default is deliberately true: when an agent calls other agents, every child call produces its own runs row and the list fills with runs the user never started. Child runs appear as a tree inside their own root’s detail view; set this to false for the full list.

Gets the run whose direct children are returned.

public Guid? ParentRunId { get; init; }

Guid?

When a value is given, RunQuery.OnlyRootRuns is ignored: asking for child runs and filtering to roots contradict each other, and silently returning an empty list is hard to debug.

Gets the tree whose runs are returned, including the root.

public Guid? RootRunId { get; init; }

Guid?

Gets the session whose runs are returned.

public string? SessionId { get; init; }

string?

Gets the number of records to skip.

public int Skip { get; init; }

int

Gets the lower bound on start time (UTC).

public DateTimeOffset? StartedAfter { get; init; }

DateTimeOffset?

Gets the status whose runs are returned.

public RunStatus? Status { get; init; }

RunStatus?

Gets the maximum number of records to return.

public int Take { get; init; }

int

Gets the tenant whose runs are returned.

public string? TenantId { get; init; }

string?

Gets the user whose runs are returned. null includes every user, including runs that carry no user at all.

public string? UserId { get; init; }

string?

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(RunQuery? other)

other RunQuery?

bool

public override int GetHashCode()

int

public override string ToString()

string

public static bool operator ==(RunQuery? left, RunQuery? right)

left RunQuery?

right RunQuery?

bool

public static bool operator !=(RunQuery? left, RunQuery? right)

left RunQuery?

right RunQuery?

bool