Skip to main content

Headless Chat & Voice SDK

The Knock Knock widget can run headless — with no Knock Knock UI at all. Your own interface drives AI chat and AI voice calls through a small JavaScript SDK, while Knock Knock handles the AI, sessions, and infrastructure behind the scenes.

This is for developers who want a completely custom look and feel: a chat panel that matches your design system, a voice assistant embedded in your product, or an AI experience that doesn't look like a widget at all.

What the SDK Can Do

  • Initialize — set up the SDK on your page with KnockKnockSDK.init
  • AI chat — send chat messages from your UI and receive the AI's replies and typing events
  • AI voice calls — start, end, and mute AI voice calls, with live transcripts and audio levels you can render however you like
  • Outbound phone calls — request an AI outbound phone call to a visitor-provided number with requestCall. The server validates the phone number, enforces your outbound-calling settings, and applies rate limits and do-not-contact suppression.

Scope

The headless SDK covers AI chat and AI voice only. Video calls and human-agent escalation are not available in headless mode — if you need those, use the standard widget instead.

Prerequisites

  • AI chat and/or AI voice enabled on your account
  • For outbound phone calls: an outbound calling agent configured and outbound calling enabled

Developer Documentation

The widget Install tab's Headless SDK section is your starting point. It includes:

  • Copyable quick-start snippets, including an outbound-call example using KnockKnockSDK.requestCall
  • A shareable Full developer documentation link — a public docs page with the complete API reference and a live demo, personalized with your company id, so your developer can open it without logging in
  • A troubleshooting table covering the most common setup issues, such as the widget not appearing or requestCall returning outbound_unavailable
note

This page is a high-level overview. For method signatures, events, and integration examples, always refer to the SDK docs page linked from the Install tab — it stays in sync with the latest SDK version.

note

For agency white-label accounts, the embed snippet and the developer docs link automatically use your white-label API origin — nothing to configure.