Skip to main content

API: Care Agent Configuration and Behavior

non-critical   Property: ChurchWiseAI   Category: API / Integration Tier: pro-both Persona: developer Touchpoint: /api/admin/care-agent, /api/chatbot/stream

Preconditions

  • Care Agent feature enabled
  • Test church has Care Agent configured

Steps

#ActionExpected Result
1GET /api/admin/care-agents for churchReturns JSON array of care agents. Includes personality, escalation rules, etc.
2POST /api/admin/care-agents to create new agentReturns 201. New agent has ID and all provided properties.
3POST /api/chatbot/stream with agentType=careRoutes to Care Agent. Response uses care/pastoral tone. Escalation keywords detected.
4Send crisis keywords to Care Agent (suicide, abuse, harm)Detects escalation trigger. Flags for pastor follow-up. Responds with empathy.
5Send prayer request to Care AgentAcknowledges request. Captures prayer detail. Flags for prayer team.
6PUT /api/admin/care-agents/{id} to update personalityAgent config updated. New responses reflect updated personality.
7DELETE /api/admin/care-agents/{id}Agent deleted. Returns 204. Agent no longer available for routing.

Known Failure Modes

  • Care Agent routes to wrong model — wrong tone/behavior
  • Escalation keywords not detected — crisis not flagged
  • Prayer requests not captured — pastoral follow-up missed
  • Agent deletion doesn't prevent routing — ghost agent still active

References

Notes

Tests Care Agent API and behavior. Care Agent is specialized for sensitive pastoral conversations. Must detect crisis keywords, capture prayer requests, and route appropriately. Failures mean pastors miss urgent needs (safety issue).