Skip to content

ToolApprovalDecision

Namespace AgentPrism · Assembly AgentPrism.AspNetCore.dll

Tool approval decision sent from the UI.

public sealed record ToolApprovalDecision : IEquatable<ToolApprovalDecision>

objectToolApprovalDecision

IEquatable<ToolApprovalDecision>

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

The decision is carried in the body of the next run request. Microsoft Agent Framework expects the approval response as a ChatMessage content item; there is no separate “continue” endpoint, because approval is the input to the next turn.

public ToolApprovalDecision()

Whether the call is approved.

public required bool Approved { get; init; }

bool

Reason for the decision. Passed on to the model.

public string? Reason { get; init; }

string?

Whether the decision should be saved as a permanent rule (“don’t ask again”). Meaningful only while Approved is true.

public bool Remember { get; init; }

bool

Whether the permanent rule covers only a call with the same arguments. If false, it covers every call to the tool.

public bool RememberArgumentsOnly { get; init; }

bool

Identifier of the approved request. This is the ToolApprovalRequestContent.RequestId value received in the stream.

public required string RequestId { get; init; }

string

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(ToolApprovalDecision? other)

other ToolApprovalDecision?

bool

public override int GetHashCode()

int

public override string ToString()

string

operator ==(ToolApprovalDecision?, ToolApprovalDecision?)

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

left ToolApprovalDecision?

right ToolApprovalDecision?

bool

operator !=(ToolApprovalDecision?, ToolApprovalDecision?)

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

left ToolApprovalDecision?

right ToolApprovalDecision?

bool