Skip to main content

ApprovalToolRunner

@retinue/monorepo


@retinue/monorepo / backend/src / ApprovalToolRunner

Interface: ApprovalToolRunner

Defined in: backend/src/hitl/approved-execution.ts:48

What this module needs from the tool layer — the registry satisfies it.

Structural rather than ToolRegistry so the coupling is exactly two methods wide, and so a host that runs tools some other way can still use the loop.

Methods​

execute()​

execute(context, input): Promise<ToolResult>

Defined in: backend/src/hitl/approved-execution.ts:49

Parameters​

context​

ExecutionContext

input​
approval?​

OneTimeApprovalRef

idempotencyKey?​

string

input​

unknown

name​

string

Returns​

Promise<ToolResult>


learn()​

learn(context, names): Promise<readonly ToolDescriptor[]>

Defined in: backend/src/hitl/approved-execution.ts:59

Resolves descriptors for names the caller is authorized to use; unauthorized names are absent.

Parameters​

context​

ExecutionContext

names​

readonly string[]

Returns​

Promise<readonly ToolDescriptor[]>