healthcare
Weave CLI for Cron Jobs
Use the Weave CLI for cron jobs with headless JSON commands, schema discovery, credentials, and permission controls.
7 functions 7 read 0 write Bearer token auth
Weave CLI for Cron Jobs
Schedule repeatable integration workflows from cron while keeping credentials in KosmoKrator config.
Use the headless CLI from cron when an operation should run without an interactive agent session. The Weave CLI uses the same integration registry as the TUI, Lua runtime, and MCP gateway, but returns predictable command output for automation.
Command Shape
# Weave CLI for Cron Jobs
kosmokrator integrations:configure weave --set access_token="$WEAVE_ACCESS_TOKEN" --enable --read allow --write ask --json
kosmo integrations:call weave.weave_list_patients '{"limit":1,"page":1,"query":"example_query"}' --json Discovery Before Execution
Agents and scripts can inspect Weave docs and schemas before choosing a function.
kosmo integrations:docs weave --json
kosmo integrations:docs weave.weave_list_patients --json
kosmo integrations:schema weave.weave_list_patients --json
kosmo integrations:search "Weave" --json
kosmo integrations:list --json Useful Weave CLI Functions
| Function | Type | Parameters | Description |
|---|---|---|---|
weave.weave_list_patients | Read | limit, page, query | Search and list patients from Weave. Returns patient records with names, contact info, and metadata. Use the query parameter to search by name, phone, or email. |
weave.weave_get_patient | Read | id | Retrieve a single patient by ID. Returns full patient details including demographics and contact information. |
weave.weave_list_appointments | Read | startDate, endDate, limit | List appointments from Weave with optional date range filtering. Returns appointment records with patient info, scheduled times, and status. |
weave.weave_get_appointment | Read | id | Retrieve a single appointment by ID. Returns full details including patient info, scheduled time, duration, and status. |
weave.weave_list_messages | Read | limit, page, type | List patient messages from Weave with optional type filtering. Returns message records with sender, recipient, content previews, and status. |
weave.weave_get_message | Read | id | Retrieve a single message by ID. Returns full message content, sender, recipient, timestamps, and delivery status. |
weave.weave_get_current_user | Read | none | Get the currently authenticated Weave user profile. Returns user details including name, email, role, and organization info. |
Automation Notes
- Use
--jsonfor machine-readable output. - Keep credentials out of argv by using environment variables or stored KosmoKrator configuration.
- Configure read/write policy before unattended runs; use
--forceonly for trusted automation. - Use the MCP gateway instead when the agent needs dynamic tool discovery inside a conversation.