Skip to content

ToolAuthorizationRequest

Namespace AgentPrism · Assembly AgentPrism.Abstractions.dll

Describes one tool call awaiting an authorization decision.

public sealed record ToolAuthorizationRequest : IEquatable<ToolAuthorizationRequest>

objectToolAuthorizationRequest

IEquatable<ToolAuthorizationRequest>

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

public ToolAuthorizationRequest()

Gets the name of the agent making the call.

public required string AgentName { get; init; }

string

Gets the tool’s effect class.

public required ToolEffect Effect { get; init; }

ToolEffect

Gets the permission name the tool declared, or null when the tool declared none.

public string? RequiredPermission { get; init; }

string?

This is an opaque string. AgentPrism does not resolve, validate, or store its meaning anywhere but the audit trail — only the handler interprets it.

Gets the identity of the run making the call.

public required Guid RunId { get; init; }

Guid

Gets the calling run’s tenant.

public required string TenantId { get; init; }

string

Gets the tool name.

public required string ToolName { get; init; }

string

Gets the calling run’s user, or null when unknown.

public string? UserId { get; init; }

string?

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(ToolAuthorizationRequest? other)

other ToolAuthorizationRequest?

bool

public override int GetHashCode()

int

public override string ToString()

string

operator ==(ToolAuthorizationRequest?, ToolAuthorizationRequest?)

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

left ToolAuthorizationRequest?

right ToolAuthorizationRequest?

bool

operator !=(ToolAuthorizationRequest?, ToolAuthorizationRequest?)

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

left ToolAuthorizationRequest?

right ToolAuthorizationRequest?

bool