Benefits Enrollment Outreach
Proactively contact eligible residents to assist with benefits enrollment, reduce gaps in coverage, and improve program uptake rates.
Why this matters
Reach constituents at scale for benefits enrollment, permit follow-ups, public health outreach, and emergency notifications. This example shows you how to automate benefits enrollment outreach calls end-to-end with Guava's SDK — no telephony plumbing, no prompt engineering, just Python.
Installation
Install from Guava's private PyPI index. A public package is coming soon — the install command will simplify to pip install guava.
# Step 1: Install Guava
pip install gridspace-guava --extra-index-url https://guava-pypi.gridspace.com
# Public PyPI package coming soon — the install command will simplify to:
# pip install guava
# Step 2: Set your credentials
export GUAVA_API_KEY="..."
export GUAVA_AGENT_NUMBER="..."How it's built
Every Guava agent is a Python class. Walk through the key sections below, then grab the complete file at the end.
Imports
Import the Guava SDK and any helpers you need. guava.CallController is the base class for every voice agent.
# Install: pip install gridspace-guava --extra-index-url https://guava-pypi.gridspace.com
import guava
import osAgent setup
set_persona() defines how the agent presents itself. set_task() gives it its mission in plain English. The checklist drives the conversation — Guava works through it top-to-bottom, collecting Field values and speaking Say items as it goes.
class BenefitsEnrollmentBot(guava.CallController):
def __init__(self, resident_name: str, program_name: str, agency: str, deadline: str):
super().__init__()
self.set_persona(
organization_name=agency,
agent_name="Alex",
)
self.set_task(
objective=f"Help {resident_name} enroll in {program_name} before the {deadline} deadline",
checklist=[
f"Identify yourself as calling from {agency} regarding {program_name} enrollment.",
guava.Say(f"Records indicate {resident_name} may be eligible. Enrollment deadline is {deadline}."),
guava.Field(
key="wants_information",
field_type="bool",
description="Would they like to learn more about the program benefits?",
),
guava.Field(
key="currently_enrolled",
field_type="bool",
description="Are they already enrolled in this or a similar program?",
),
guava.Field(
key="wants_to_apply",
field_type="bool",
description="Would they like to begin the application now?",
),
guava.Field(
key="preferred_application_method",
field_type="choice",
description="Preferred way to complete the application",
choices=["phone now", "online portal", "in-person office visit", "mail-in form"],
),
guava.Field(
key="language_preference",
field_type="choice",
description="Preferred language for application materials",
choices=["English", "Spanish", "Chinese", "Vietnamese", "other"],
),
"Provide application link or transfer to enrollment specialist.",
],
on_complete=lambda fields: print(f"Benefits outreach complete: {resident_name} — {fields}"),
)
guava.dial(
controller=BenefitsEnrollmentBot,
controller_args={"resident_name": "Maria Gonzalez", "program_name": "CalFresh Food Assistance",
"agency": "County Department of Social Services",
"deadline": "December 31"},
to=os.environ["RESIDENT_PHONE"],
agent_number=os.environ["GUAVA_AGENT_NUMBER"],
api_key=os.environ["GUAVA_API_KEY"],
)Platform performance
<1s
Response time
99.99%
Uptime SLA
13+
Industries served
Full example
The complete file — copy it, save it as example.py, and run it.
# Install: pip install gridspace-guava --extra-index-url https://guava-pypi.gridspace.com
import guava
import os
class BenefitsEnrollmentBot(guava.CallController):
def __init__(self, resident_name: str, program_name: str, agency: str, deadline: str):
super().__init__()
self.set_persona(
organization_name=agency,
agent_name="Alex",
)
self.set_task(
objective=f"Help {resident_name} enroll in {program_name} before the {deadline} deadline",
checklist=[
f"Identify yourself as calling from {agency} regarding {program_name} enrollment.",
guava.Say(f"Records indicate {resident_name} may be eligible. Enrollment deadline is {deadline}."),
guava.Field(
key="wants_information",
field_type="bool",
description="Would they like to learn more about the program benefits?",
),
guava.Field(
key="currently_enrolled",
field_type="bool",
description="Are they already enrolled in this or a similar program?",
),
guava.Field(
key="wants_to_apply",
field_type="bool",
description="Would they like to begin the application now?",
),
guava.Field(
key="preferred_application_method",
field_type="choice",
description="Preferred way to complete the application",
choices=["phone now", "online portal", "in-person office visit", "mail-in form"],
),
guava.Field(
key="language_preference",
field_type="choice",
description="Preferred language for application materials",
choices=["English", "Spanish", "Chinese", "Vietnamese", "other"],
),
"Provide application link or transfer to enrollment specialist.",
],
on_complete=lambda fields: print(f"Benefits outreach complete: {resident_name} — {fields}"),
)
guava.dial(
controller=BenefitsEnrollmentBot,
controller_args={"resident_name": "Maria Gonzalez", "program_name": "CalFresh Food Assistance",
"agency": "County Department of Social Services",
"deadline": "December 31"},
to=os.environ["RESIDENT_PHONE"],
agent_number=os.environ["GUAVA_AGENT_NUMBER"],
api_key=os.environ["GUAVA_API_KEY"],
)Run it
Start the agent. It will connect to Guava's infrastructure and begin accepting calls on your assigned number.
python example.py