Authentication and enablement
The tools use the Nanonets Health integration. The platform injectsapi_key. That key is never part of the model-visible schema, and it scopes every call to the connected Nanonets Health organization. All three tools are disabled by default.
Every tool takes agent_id, the Nanonets Health custom-agent id (UUID) whose dashboard the run belongs to. Put it in the agent’s instructions; it cannot be discovered.
Flow
- Call
nanonetshealth_start_agent_runonce at the start of the run and keep itsrun_log_id. - Call
nanonetshealth_report_agent_itemonce for every item, including skips and failures. - Call
nanonetshealth_complete_agent_runonce, after the last item.
nanonetshealth_start_agent_run
Inputs:
agent_id(required)external_run_id: optional. This platform’s own run or task id, recorded on the run log for cross-reference.
nanonetshealth_report_agent_item
Inputs:
agent_id,run_log_id,item_key,status(all required)patient_id,visit_id,appointment_date,reason,decision,error: optional stringsitem,outcome: optional JSON objects. A string holding a JSON object is also accepted.
status is one of updated, mips_found, completed, skipped, needs_va, accepted, check_required, declined, dry_run, scored, reviewed, failure, failed. Nanonets Health stores failed as failure.
Idempotent per run_log_id + item_key: reporting the same key again replaces the earlier row, so a retry never duplicates an item.
Output:
nanonetshealth_complete_agent_run
Inputs:
agent_id,run_log_id(required)status: optional. One ofsuccess,partial_success,failure. If you omit it, Nanonets Health derives it from the reported items:failureif every item failedpartial_successif some items failedsuccessotherwise
output: optional JSON object, such as counts per status.
Expected errors
The tools return Nanonets Health’s own error text:
These tools require the Nanonets Health release that adds external runs (fleming PR #467).