Skip to content

WorkflowSaveRequest

Namespace AgentPrism · Assembly AgentPrism.AspNetCore.dll

Request to save a workflow definition.

public sealed record WorkflowSaveRequest : IEquatable<WorkflowSaveRequest>

objectWorkflowSaveRequest

IEquatable<WorkflowSaveRequest>

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

The name comes from the path, not the body. Having two sources would raise the question of which one wins when they conflict.

public WorkflowSaveRequest()

Names of agents to add to the graph.

public IReadOnlyList<string>? AgentNames { get; init; }

IReadOnlyList<string>?

Short description of what the workflow does.

public string? Description { get; init; }

string?

Name shown in the UI.

public string? DisplayName { get; init; }

string?

Handoff instructions. Only for WorkflowKind.Handoff.

public string? HandoffInstructions { get; init; }

string?

Built-in pattern to use.

public WorkflowKind Kind { get; init; }

WorkflowKind

Name of the manager agent. Only for WorkflowKind.Magentic.

public string? ManagerAgentName { get; init; }

string?

Maximum number of turns.

public int? MaxIterations { get; init; }

int?

Ordered agent/function node list for a Sequential workflow that mixes function nodes in with agents. Mutually exclusive with WorkflowSaveRequest.AgentNames; leave both empty or set only one.

public IReadOnlyList<WorkflowNodeReference>? Nodes { get; init; }

IReadOnlyList<WorkflowNodeReference>?

Whether the manager agent’s plan must be approved by a human. Only for WorkflowKind.Magentic.

public bool RequirePlanApproval { get; init; }

bool

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(WorkflowSaveRequest? other)

other WorkflowSaveRequest?

bool

public override int GetHashCode()

int

public override string ToString()

string

operator ==(WorkflowSaveRequest?, WorkflowSaveRequest?)

Section titled “ operator ==(WorkflowSaveRequest?, WorkflowSaveRequest?)”
public static bool operator ==(WorkflowSaveRequest? left, WorkflowSaveRequest? right)

left WorkflowSaveRequest?

right WorkflowSaveRequest?

bool

operator !=(WorkflowSaveRequest?, WorkflowSaveRequest?)

Section titled “ operator !=(WorkflowSaveRequest?, WorkflowSaveRequest?)”
public static bool operator !=(WorkflowSaveRequest? left, WorkflowSaveRequest? right)

left WorkflowSaveRequest?

right WorkflowSaveRequest?

bool