Workflows
Gooclaim ships three workflows in v1.0. Each one runs end-to-end without
human intervention for the happy path, falling back to a human only when
policy or knowledge gaps demand it.
The three workflows
Read-only status lookup. Claimant asks where their claim is; Gooclaim fetches from your CMS and replies via a templated message.
Stateful follow-up. Gooclaim asks for the documents you marked pending, waits, reminds, and notifies you when the claimant uploads.
KB-backed explanation. Claimant asks “why?” — Gooclaim finds the answer in your knowledge base, runs it through the Policy Gate, and replies.
How a workflow runs
Every workflow follows the same six-stage pipeline:
Every step emits an audit event you can query via the Audit Ledger API.
Claim Status
Trigger: Claimant sends “status” / “claim status” / equivalent in HI/EN/HI_EN on WhatsApp.
Flow:
- Gooclaim recognizes intent (template match — no free-text LLM)
- Identity gate matches phone → claim record
- Truth Layer pulls live status from your CMS (with circuit breaker)
- Template selected per channel + language
- Outbound dispatches the reply
Typical end-to-end latency: under 3 seconds.
Sample status query:
Pending Documents
Trigger: Your CMS marks a claim as DOCUMENTS_PENDING (push) or
claimant asks “what’s pending?” (pull).
Flow:
- Gooclaim retrieves the pending-docs list from your CMS
- Templated reminder dispatched (“Please upload X, Y, Z”)
- Temporal workflow waits up to 72 hours
- If documents arrive → notifies you via webhook
- If timeout → escalates to your team
This is a durable workflow — restarts, deploys, and incidents do not lose
state. Each pending workflow has a pending_docs_workflow_id you can resume
or cancel.
Cancel a pending-docs workflow:
Query Reason
Trigger: Claimant asks “why” — rejection reason, deduction reason, delay reason.
Flow:
- Intent classified as
query-reason - Knowledge Layer searches your tenant-specific KB (Airweave-backed)
- Cache check via Template Registry — has this exact question been answered?
- If miss → KB result passes through the Policy Gate:
- Tier 1: exact-match deny list
- Tier 2: semantic check (Guardrails AI)
- Tier 3: PHI redaction
- Tier 4: source attribution check
- Templated reply with the cited reason
If the Policy Gate blocks the answer (e.g. answer would contain PHI it
shouldn’t, or no trusted source can back the claim), the workflow ends with
status policy_blocked and the claimant is told a human will follow up.
Operational modes
Every tenant has an operational mode that gates workflow execution:
Your current operational mode is shown in the Portal’s tenant settings view.
Mode changes are also pushed as operational_mode.changed webhook events
(see Webhooks).
Workflow events
Every state transition emits a webhook to your configured URL. See Webhooks for the full event catalog.
Next: receive workflow events
Head to Webhooks to subscribe to lifecycle events from your side.