Tool declaration
Private client input contract
Exports
Agent
Managed agent definition lowered by the selected Harnest backend.— means no declared default):
Parameters and example
Parameters and example
Agent.advanced
Parameters and example
Parameters and example
Agent.build
Example
Example
AgentDefinition
Managed agent definition lowered by the selected Harnest backend.— means no declared default):
Parameters and example
Parameters and example
AgentDefinition.advanced
Parameters and example
Parameters and example
AgentDefinition.build
Example
Example
AgentRuntimePermissionError
A capability is unavailable to the active Agent Runtime Principal.Example
Example
AgentRuntimePrincipal
Identify one default-deny invocation and its permission grants.— means no declared default):
Parameters and example
Parameters and example
AgentRuntimePrincipal.create
Parameters and example
Parameters and example
AgentRuntimePrincipal.restrict
Parameters and example
Parameters and example
ClientToolError
A client tool request could not be completed safely.Example
Example
ClientToolExecution
Runtime capability visible only while Harnest owns an invocation.— means no declared default):
Parameters and example
Parameters and example
ClientToolExecution.execute
Parameters and example
Parameters and example
ClientToolExecution.transient_media
Return private media access already scoped to this invocation.Example
Example
InMemoryClientToolStore
Development store for one-time client tool result delivery.Parameters and example
Parameters and example
InMemoryClientToolStore.transient_media
Expose the lease boundary to framework adapters, never to clients.Example
Example
InMemoryClientToolStore.suspend
Parameters and example
Parameters and example
InMemoryClientToolStore.submit
Parameters and example
Parameters and example
InMemoryClientToolStore.run_for
Parameters and example
Parameters and example
InMemoryClientToolStore.pending_for
Parameters and example
Parameters and example
InMemoryClientToolStore.cancel
Parameters and example
Parameters and example
PendingClientTool
One principal-scoped client tool call awaiting its result.— means no declared default):
Parameters and example
Parameters and example
PendingClientTool.public
Example
Example
ToolCallRequest
Provider-neutral arguments for one managed tool call.— means no declared default):
Parameters and example
Parameters and example
ToolLifecycleContext
Stable invocation identity associated with one managed tool call.— means no declared default):
Parameters and example
Parameters and example
ToolLifecycleContext.next
Parameters and example
Parameters and example
ToolLifecycleContext.finish
Parameters and example
Parameters and example
ToolLifecycleError
A tool interceptor returned invalid or ambiguous control flow.Example
Example
approval
Seeharnest.agent.approval for its exports.
client_input
Collect private input for an async handler and return only authored JSON. The handler’s first positional parameter receives the validated private input and is excluded from the model tool signature. Remaining parameters are public request arguments. The handler must return None.response
is frozen at declaration time and is the only successful model result.
Parameters and example
Parameters and example
client_tool
Declare a client tool with an optional runtime-principal permission tag.Parameters and example
Parameters and example
client_tool_execution
Activate client-tool execution authority for the current context.Parameters and example
Parameters and example
current_transient_media
Expose scoped staged bytes only during a managed invocation.Example
Example
instruction_file
Read an instruction file relative to a Python module. Pass__file__ as anchor so the path remains correct in a deployed
bundle and does not depend on the process working directory.
Parameters and example
Parameters and example
tool
Mark a typed Python function as a managed Harnest agent tool. Both managed backends wrap callables natively. This decorator preserves the function’s typed signature, checks that the model receives a description, validates an optional Pydantic result, and installs declared execution policy before backend lowering. Durable tools cross a framework-native suspension boundary and therefore must be asynchronous.Parameters and example
Parameters and example