call-me-back
Resume this agent session on a completion signal instead of clock polling. Use when wiring external hooks/--exec/webhooks that must POST into this session (wake URL is already in Agent Runtime Identit
SKILL.mdsrc-tauri/bundled_skills/call-me-back/SKILL.md
GitHubCall Me Back (event-driven resume)
Wait for an external or process completion signal, then continue this
session. Do not fake completion with scheduleCallback / loop delays.
"me" = this agent session (inject/resume here), not a user phone/SMS alert.
vs loop / schedule (hard split)
| Signal | Skill |
|---|---|
| Process exit, job/ticket done, webhook, watcher, hook | call-me-back (this skill) |
| Relative delay / wall-clock / session cron | loop |
| Permanent app-wide cron | schedule |
If the user says "끝나면 알려줘" and names a command, job, ticket, or external system,
use this skill. If they only name a clock time, use loop.
Typical jobs
- Heavy local jobs: builds, tests, training, long scripts
- Background process already started via
workspace__spawnProcess - External systems that fire on real events (hooks, webhooks, watchers)
- Waiting for a named job/ticket/status change (not a clock guess)
Out of scope
- "Remind me in 10 minutes" / "내일 9시에" →
loop - Always-on global cron with no session binding →
schedule - Immediate child-session work with no wait →
delegate
Workflow
A. Local long-running command
- Start (or reuse) a background process:
workspace__spawnProcess(or a sync tool that handed off aprocessId). - Block on completion — do not poll with
loop:workspace__waitForProcess(processId=..., timeout=...)(waitForProcesswakes on process notify; it is the built-in call-me-back for shells.) - On finish, read output if needed:
workspace__readProcessOutput(processId=...) - Continue the user task with the result (pass/fail, logs, next steps).
Prefer one waitForProcess over repeated short waits or clock callbacks.
B. External systems (hooks / webhooks / watchers)
Success = a message lands in this LibrAgent session and the workflow resumes. Stdout from an external gateway/hook process is not resume.
Contract (product-agnostic)
Whatever registers the external callback (hook command, webhook URL, watcher script) must wake this harness by injecting into this session. Do not add per-product recipes to this skill — read that system's own hook docs, then wire its payload here.
Harness wake (SSOT):
Agent Runtime Identity already injects the concrete wake URL for this session
(External wake (this session): POST http://127.0.0.1:<port>/api/sessions/<id>/messages).
Copy that URL — do not invent a path or leave --exec as echo / file-append only.
- Body: JSON
{"content":"<event summary>"}(optional"source":"api"). - Channel-style alternative:
POST …/channelwithserverName+content(+ optionalmeta).
Map the external event (env, stdin JSON, query, body) into that content / meta.
The external side only needs to run something that performs this inject.
Two phases
- Register the external callback once (that system's register API).
- When woken (this session receives the inject): continue the original task here.
Do not treat “callback registered” as done unless wake/inject is wired. Do not assume work done only inside the external callback will appear in this chat.
Anti-patterns
- External callback that only logs,
echos, or appends a file — no session inject - Registering
--exec/ a webhook without the Runtime Identity wakePOST - “Callback runs outside this process so it cannot reach this chat” — false; inject is the reach
- Blocking long-poll / foreground watchers when a non-blocking register-callback API exists
- Faking completion with
scheduled_task__scheduleCallback/loopdelays
If the system only offers coarse polling
Prefer its native wait/watch over LibrAgent clock loops, and keep poll intervals honest in the reply. Prefer inject/wake whenever a callback hook exists.
C. Ambiguous "끝나면 알려줘"
- Named process/command/job/ticket/system → this skill
- Only a duration or clock time →
loop - Still unclear → ask once: time-based reminder, or wait for a specific completion?
Guardrails
- Do not use
scheduled_task__scheduleCallbackas a stand-in for job completion. - Do not busy-poll via many tiny
loopdelays or LLM turn spam. - Do not invent
processIdvalues; only use ids returned by workspace tools. - Do not treat this skill as user push-notification / telephony.
- Keep session context: completion should resume this chat unless the user
explicitly asked for a global scheduled worker (
schedule). - Do not invent per-product command catalogs in this skill; reuse the inject contract.
Related skills
loop— clock-based session reminders and recurring checksschedule— global cron automationdelegate— spawn work in a child session nowlibragent-harness-reference— HTTP inject path / session id factsteamwork/org— multi-agent constitution; not required for a single wait