Setup
How to set up lead capture for sleep study after hours bo…
How to set up lead capture for sleep study after hours booking — answered from your own docs. How Sleep Clinics teams use Chatref (lead capture, lead capture) t
When patients request a sleep study outside office hours, your website becomes a silent front desk. Chatref can capture those after-hours leads by answering visitors from your practice’s own sleep study details, then collecting their contact information right in the chat—turning overnight inquiries into scheduled follow-ups.
Before you start
You need an active Chatref account with an agent trained on your sleep clinic’s operational details. The agent must know your sleep study types (in-lab, home-based), current availability, and—most critically—your office hours. Without that information, the after-hours logic will not differentiate between open-hours booking and overnight capture.
What to prepare:
- Practice hours document: A PDF, page, or plain text listing your exact open and close times for every day, including weekends and holidays.
- Sleep study content: Details about the types of studies you offer, what a patient needs before booking, and any prerequisites or insurance guidance. This populates the knowledge base and keeps the conversation grounded.
- Lead capture form fields: Decide exactly what you need from a patient who cannot book immediately. Typically: full name, best phone number, email, and a free-text “preferred callback time” field. The fewer fields, the higher the completion rate.
Add these materials to your agent under Knowledge in the Chatref dashboard. The agent learns in minutes. Once the content is loaded, the agent answers sleep study questions from your own documentation—no generic guesses—and can recognize when a question arrives after hours.
Step-by-step setup
1. Train the agent on after-hours context
Your knowledge base must make your availability unambiguous. Upload a document or plain text that explicitly states:
- “Our practice is open Monday through Friday from 8:00 AM to 5:00 PM EST. We are closed Saturdays, Sundays, and on national holidays.”
- “Sleep study requests received outside these hours will be collected, and a coordinator will call back the next business morning.”
This gives the agent the fact-set it needs to determine when to follow booking procedures versus when to shift to lead capture. Without it, the agent may default to “book now” logic at any time, causing confusion.
2. Enable and configure lead capture
In Chatref, lead capture is a feature built into every widget. Navigate to your agent’s Widget Settings and find the Lead Capture section.
- Toggle the lead capture action on.
- Add the fields you decided on. A typical sleep clinic setup:
- Full Name (text, required)
- Phone (text, required)
- Email (text, required)
- Best Time to Call (text or dropdown: “Morning (9-12)”, “Afternoon (12-5)”, “Evening”)
- Write a short confirmation message the patient sees after submitting, such as “Thank you. Our sleep study coordinator will call you on the next business day.”
Chatref will insert this form into the conversation thread when lead capture is triggered.
3. Connect after-hours logic
Lead capture does not trigger on its own—it needs a reason. Write a custom prompt for the agent that ties sleep study requests and after-hours detection together. Go to the agent’s Settings > Agent Prompt and add instructions like:
When a visitor asks about scheduling a sleep study and the current time is outside our posted office hours, do not offer a booking slot. Instead, explain that our practice is closed, confirm the visitor’s interest, and trigger the lead capture form so a coordinator can reach them on the next business morning. If multiple sleep study types are mentioned, briefly outline the differences first, then collect their details.
This prompt marries the knowledge base (hours, study types) with the lead capture action. The agent’s retrieval system will ground its response in your documents, so it always uses your actual hours—not an assumed 9-to-5.
4. Review and adjust fallback behavior
When a known after-hours request arrives, the agent should move directly to lead capture. But if a visitor asks a question that is only partially about after-hours booking—for example, “How long does a home sleep study take and can I book one now?”—the agent may answer the informational question first, then ask about scheduling. That is fine, but you should test that lead capture still appears before the conversation ends. If the patient disengages early, a stale thread becomes a lost lead.
To cover this, set a conversation timeout. In Widget Settings, you can define that after N seconds of visitor inactivity, the agent sends an outreach message like “I’m still here. If you’d like a callback about the sleep study, just ask.” This keeps the door open for lead capture on a longer, meandering thread.
Check it works
Test two scenarios from an incognito browser:
- During simulated after-hours
- Set your browser time to 9:00 PM on a Wednesday (a day your practice is closed, per your documents).
- Open your website’s Chatref widget and type: “Can I schedule a home sleep study?”
- The agent should not offer a time slot. Instead, it should acknowledge the after-hours status, restate that a coordinator will call back, and present the lead capture fields.
- Fill and submit the form. Verify the submission appears under Conversations in your Chatref inbox.
- During simulated business hours
- Set your browser time to 10:00 AM on a Tuesday.
- Ask the same question. The agent should now describe the sleep study and either guide you toward booking instructions or direct you to a scheduling link (if you’ve added one). It should not automatically trigger lead capture.
If the after-hours trigger does not fire, revisit the Agent Prompt. Make sure your hours document is clear and that the prompt explicitly ties “outside office hours” to the lead capture action. Also confirm the knowledge base is fully processed and returning the hours content in the agent’s playground.
Common issues
The agent offers a booking instead of lead capture after hours.
Most often, your hours document is too vague. Statements like “we close at 5” are insufficient—the agent needs day-of-week granularity and timezone. Provide unambiguous hours in a structured block, such as:
Office Hours (Eastern Time)
Mon–Fri: 8:00 AM – 5:00 PM
Sat–Sun: Closed
Then mirror that in the Agent Prompt’s after-hours condition.
Lead capture form doesn’t appear even when the agent says it will.
The most common cause is that lead capture is toggled off in Widget Settings or a required field name contains illegal characters. Revisit the configuration, save, and clear your browser cache before retesting. If the issue persists, the agent may be responding with a message that does not call the lead capture action. Update the prompt to phrase the handoff more directly: “Now, I’ll collect your contact information so a sleep study coordinator can reach you.”
The agent collects details but never mentions the next-day callback.
The confirmation message is separate from the agent’s reply. Customize it by editing the Lead Capture settings and making the post-submit message specific: “Thanks, [Name]. A coordinator will call you by noon tomorrow Eastern Time.”
Patients abandon before submitting the form.
Long forms kill capture rates. Reduce fields to the absolute minimum required for a callback—typically name and phone. Email and callback preference can be optional. Test a three-field capture and compare completion rates to your original form.
After-hours detection fails across time zones.
Patients in different zones will reach your widget at different local times. Always set your office hours in a specific timezone (e.g., Eastern) and document that. Chatref uses the visitor’s local time, so the Agent Prompt should compare “current time in Eastern Time” to your posted hours. In practice, most sleep clinics serve a single region; document your regional timezone prominently in the knowledge base.
FAQ
What causes sleep study after hours booking problems for Sleep Clinics?
Most problems trace back to incomplete practice information. If your hours, sleep study types, or scheduling policies are not clearly recorded in your Chatref knowledge base, the agent cannot distinguish between business-hour bookings and after-hours inquiries. Patients then receive generic “book now” prompts at 10 PM, or the agent fails to collect their details at all. Other contributors: lead capture fields that are too long, agent prompts that don’t explicitly connect after-hours detection to lead capture, and timezone ambiguity. For sleep clinics, see Sleep Clinics for industry-specific guidance.
How do I improve sleep study after hours booking for Sleep Clinics?
Start with your knowledge base. Add a precise, structured block of your office hours (including closures) and a separate document covering your sleep study types and prerequisites. Then, write an Agent Prompt that tells Chatref: when a sleep study booking request arrives outside those posted hours, do not offer a slot—instead, explain the situation and trigger lead capture so a coordinator follows up. Keep the capture form short (name, phone, optional best time to call) and add a clear next-day callback message. Finally, test the widget outside your published hours to confirm the agent behaves as intended.
Related guides
Put this into practice
Chatref answers your customers from your own content, day and night. Add it to your site and go live in minutes – free to start.