# Humain Kiosk ## Docs - [Welcome to Humain Kiosk](https://humain.mintlify.app/introduction.md): Ship AI conversations on any channel — kiosk terminal, phone line, website widget, or drive-through — with a single API. - [Authentication](https://humain.mintlify.app/concepts/authentication.md): Every device request is authenticated with a long-lived bearer token issued from the admin panel. - [Public Gateway](https://humain.mintlify.app/concepts/public-gateway.md): Let a browser open sessions and stream voice or text without ever holding your device credential. - [Session lifecycle](https://humain.mintlify.app/concepts/session-lifecycle.md): A session is a stateful conversation context that lives on the server. Every message exchange, voice stream, and tool call happens inside an open session. - [Session modes](https://humain.mintlify.app/concepts/modes.md): Choose the right interaction mode for your channel: text for WebSocket messaging, voice for real-time WebRTC audio, voip for telephony. - [Language support](https://humain.mintlify.app/concepts/language-support.md): Send a preferred language with every session and display the EU AI Act disclosure text. - [Sandbox](https://humain.mintlify.app/concepts/sandbox-mode.md): Test your integration without consuming LLM credits or generating billing events — using a dedicated sandbox credential, not a different URL. - [Error codes](https://humain.mintlify.app/concepts/error-codes.md): All API errors follow a consistent JSON shape with a machine-readable code, a human-readable message, and optional details. - [Rate limits](https://humain.mintlify.app/concepts/rate-limits.md): Humain applies rate limits at two levels — per-credential burst protection and per-session sustained limits — to keep the platform stable for all customers. - [Connection types](https://humain.mintlify.app/connections/overview.md): Choose the right transport for your channel. Humain supports REST, WebSocket streaming, WebRTC voice, and VoIP/SIP. - [REST — text session setup](https://humain.mintlify.app/connections/rest-text.md): Open a text session, authenticate the realtime connection, and close it — over plain HTTPS. Conversation turns themselves run over WebSocket. - [WebSocket — streaming](https://humain.mintlify.app/connections/websocket-streaming.md): Exchange text conversation turns over a persistent WebSocket connection. The only transport for text mode — there is no REST message endpoint. - [WebRTC — real-time voice](https://humain.mintlify.app/connections/webrtc-voice.md): Full-duplex audio with sub-200 ms latency, server-side VAD, and barge-in support. Runs in any browser or pion-compatible runtime. - [VoIP / SIP](https://humain.mintlify.app/connections/voip-sip.md): Bridge an existing phone line or SIP trunk to Humain without any WebRTC runtime on your device. - [Dynamic variables](https://humain.mintlify.app/guides/dynamic-variables.md): Inject per-session values — customer names, booking references, order numbers — into a kiosk's persona prompt at session open. - [Webhooks](https://humain.mintlify.app/guides/webhooks.md): Receive real-time notifications when sessions open and close, guardrails fire, and other kiosk events happen — with HMAC signature verification. - [Text playground](https://humain.mintlify.app/playground/text.md): Send real messages to a live kiosk session over WebSocket using your own device credential. - [Voice playground](https://humain.mintlify.app/playground/voice.md): Start a real WebRTC voice session with your kiosk. Speak into your microphone and hear the AI respond. - [VoIP & SIP](https://humain.mintlify.app/playground/not-testable.md): VoIP and SIP connections require a physical telephony stack and cannot be tested from a browser. Use these tools to test locally. - [Quickstart](https://humain.mintlify.app/web/quickstart.md): Add AI chat to your JavaScript app in under 5 minutes using the @humain/kiosk-js SDK. - [Drop-in widget](https://humain.mintlify.app/web/drop-in-widget.md): Add a floating chat widget to any webpage with a single script tag. No build step, no framework required. - [React](https://humain.mintlify.app/web/react.md): KioskChat, KioskVoice, and useKioskSession — React components and hooks from @humain/kiosk-js/react. - [Vue](https://humain.mintlify.app/web/vue.md): useKioskSession composable and KioskChat / KioskVoice components for Vue 3 and Nuxt. - [Svelte](https://humain.mintlify.app/web/svelte.md): Svelte store and KioskChat / KioskVoice components from @humain/kiosk-js/svelte. - [Vanilla JavaScript](https://humain.mintlify.app/web/vanilla-js.md): Use the @humain/kiosk-js core client with plain DOM APIs — no framework required. - [Streaming UI patterns](https://humain.mintlify.app/web/streaming-ui.md): Three production-ready patterns for streaming text: cursor animation, layout shift prevention, and abort/retry. - [Customising the widget](https://humain.mintlify.app/web/customisation.md): What you can change about the widget's appearance today, and what's on the roadmap. - [Widget Interface Builder](https://humain.mintlify.app/web/widget-builder.md): Configure the drop-in chat widget visually against a live preview, then copy ready-to-paste install code. - [SDKs](https://humain.mintlify.app/sdks/overview.md): Official SDKs for Python, Go, .NET, iOS, and Android — idiomatic wrappers over the Humain Device API. - [Python](https://humain.mintlify.app/sdks/python.md): asyncio-first Python SDK for Humain Kiosk — text sessions, streaming, and error handling. - [Go](https://humain.mintlify.app/sdks/go.md): Idiomatic Go SDK for Humain Kiosk — context-aware, goroutine-safe, with streaming support. - [.NET](https://humain.mintlify.app/sdks/dotnet.md): async/await .NET SDK for Humain Kiosk — text sessions, streaming, and ASP.NET Core dependency injection. - [Swift](https://humain.mintlify.app/sdks/swift.md): Native iOS and macOS SDK for Humain Kiosk — text, streaming, and WebRTC voice. - [Kotlin](https://humain.mintlify.app/sdks/kotlin.md): Native Android SDK for Humain Kiosk — text sessions, Kotlin Flow streaming, and WebRTC voice. - [iOS](https://humain.mintlify.app/mobile/ios-swift.md): Integrate Humain Kiosk into an iOS app — text chat, streaming, and real-time voice with SwiftUI. - [Android](https://humain.mintlify.app/mobile/android-kotlin.md): Integrate Humain Kiosk into an Android app — text chat, streaming, and real-time voice with Jetpack Compose. - [Voice on mobile](https://humain.mintlify.app/mobile/voice-on-mobile.md): Platform-agnostic concepts for WebRTC voice sessions on iOS and Android — VAD, barge-in, interruptions, and performance. - [iOS audio session](https://humain.mintlify.app/mobile/audio-session-ios.md): Complete AVAudioSession reference for Humain Kiosk voice integration — categories, modes, options, and notifications. - [Android audio configuration](https://humain.mintlify.app/mobile/audio-session-android.md): Complete AudioManager and AudioFocus reference for Humain Kiosk voice integration on Android. - [VoIP and telephony integration](https://humain.mintlify.app/voip/overview.md): Bridge SIP trunks, PBX systems, and cloud telephony providers to Humain Kiosk AI sessions. - [SIP gateway](https://humain.mintlify.app/voip/sip-gateway.md): Connect any SIP-capable device or PBX directly to the Humain SIP gateway — no proprietary client required. - [Asterisk AGI integration](https://humain.mintlify.app/voip/asterisk-agi.md): Route inbound calls to a Humain Kiosk session using an Asterisk AGI script and PJSIP trunk. - [Asterisk ARI integration](https://humain.mintlify.app/voip/asterisk-ari.md): Control Asterisk calls programmatically with the REST Interface and bridge them to Humain Kiosk sessions. - [Twilio](https://humain.mintlify.app/voip/twilio.md): Route Twilio phone numbers to a Humain Kiosk voice session using Media Streams and TwiML. - [Vonage](https://humain.mintlify.app/voip/vonage.md): Connect Vonage virtual numbers to Humain Kiosk using the Voice API and WebSocket audio streaming. - [Telnyx](https://humain.mintlify.app/voip/telnyx.md): Route Telnyx calls to Humain Kiosk using the Call Control API and media streaming. - [Codec guide](https://humain.mintlify.app/voip/codec-guide.md): Codec compatibility, quality trade-offs, and configuration recommendations for Humain Kiosk VoIP sessions. - [VoIP troubleshooting](https://humain.mintlify.app/voip/troubleshooting.md): Diagnose and fix the most common issues with Humain Kiosk SIP gateway integrations. - [WordPress plugin](https://humain.mintlify.app/plugins/wordpress.md): Add an AI chat widget to any WordPress site in minutes — no code required. - [FreePBX module](https://humain.mintlify.app/plugins/freepbx.md): Add Humain Kiosk AI to any FreePBX installation — no dialplan editing required. - [3CX plugin](https://humain.mintlify.app/plugins/3cx.md): Add a Humain Kiosk AI destination to 3CX using a CallFlow app — no scripting required. - [Telegram integration](https://humain.mintlify.app/telegram/overview.md): Manage kiosks from a Telegram bot, open a full workspace Mini App inside Telegram, and let a business owner's personal account auto-reply with AI. - [Telegram bot](https://humain.mintlify.app/telegram/bot.md): Manage kiosks and devices with slash commands, and connect a group chat so mentioning the bot triggers a full AI conversation. - [Telegram Mini App](https://humain.mintlify.app/telegram/mini-app.md): A full workspace-management app running inside Telegram's WebView — dashboards, kiosk management, sessions, and billing. - [Business connections](https://humain.mintlify.app/telegram/business.md): Bind a kiosk to your personal Telegram account via Business Mode so the AI answers your customer chats automatically. - [Stars payments](https://humain.mintlify.app/telegram/payments.md): Sell plan subscriptions and pay-as-you-go credit bundles through Telegram Stars — no external payment provider required. - [Embedded devices](https://humain.mintlify.app/embedded/overview.md): Run Humain Kiosk on embedded Linux, Raspberry Pi, FreeRTOS, and Zephyr using the C99 library. - [C library reference](https://humain.mintlify.app/embedded/c-library.md): Complete kiosk.h API reference — configuration, session lifecycle, streaming, error codes, memory model, and thread safety. - [Raspberry Pi](https://humain.mintlify.app/embedded/raspberry-pi.md): Build, install, and run the Humain Kiosk C library on a Raspberry Pi (arm64, Raspberry Pi OS). - [FreeRTOS](https://humain.mintlify.app/embedded/freertos.md): Integrate the Humain Kiosk C library into a FreeRTOS application — heap sizing, task setup, and text/streaming usage. - [Zephyr RTOS](https://humain.mintlify.app/embedded/zephyr.md): Integrate the Humain Kiosk C library into a Zephyr application — Kconfig options, CMakeLists.txt, and a minimal sample. - [Audio hardware](https://humain.mintlify.app/embedded/audio-hardware.md): Microphone and speaker selection guide for embedded kiosk terminals — USB, I²S, MEMS, and analogue options with STT accuracy notes. - [Credential management](https://humain.mintlify.app/embedded/credential-management.md): Secure credential storage on embedded targets — environment files, dm-crypt, ATECC608 secure element, and TPM 2.0. - [OTA updates](https://humain.mintlify.app/embedded/ota-updates.md): Keeping the kiosk library and firmware up to date — SWUpdate, Mender, and Balena Cloud, with credential preservation across updates. - [Open a session](https://humain.mintlify.app/api-reference/sessions/open-a-session.md): Creates a new conversation session for the authenticated kiosk. Returns a `session_id` and an `agent_url` — every subsequent real-time call for this session (WebSocket text, WebRTC voice, session end) goes to `agent_url`, not necessarily the host that served this request. - [Mint a WebSocket auth ticket](https://humain.mintlify.app/api-reference/sessions/mint-a-websocket-auth-ticket.md): Mints a short-lived, single-use ticket so a browser can authenticate the WebSocket upgrade in `GET {agent_url}/v1/sessions/{sid}/ws`. Browsers cannot set an `Authorization` header on a WebSocket handshake, so the raw device token never appears in the WS URL — pass this ticket as `?ticket=` instead. - [Text session (WebSocket)](https://humain.mintlify.app/api-reference/sessions/text-session-websocket.md): Upgrades to a WebSocket for text conversation turns. **Served on `agent_url`**, the base URL returned by `POST /v1/sessions` — not necessarily the host that served that request. Standard HTTP `101 Switching Protocols` response. - [End a session](https://humain.mintlify.app/api-reference/sessions/end-a-session.md): Closes the session, flushes usage events, and releases server resources. **Served on `agent_url`**, not necessarily the host that served `POST /v1/sessions`. Always call this endpoint when the conversation ends — sessions left open are cleaned up automatically after the session's time limit (default… - [Exchange WebRTC SDP offer](https://humain.mintlify.app/api-reference/voice-webrtc/exchange-webrtc-sdp-offer.md): Sends the client's SDP offer and returns the server's SDP answer. **Served on `agent_url`**, not necessarily the host that served `POST /v1/sessions`. Call this after `RTCPeerConnection.createOffer()` and `setLocalDescription()`. Once you receive the answer, call `setRemoteDescription()` on the peer… - [Submit ICE candidate](https://humain.mintlify.app/api-reference/voice-webrtc/submit-ice-candidate.md): Submits a WebRTC ICE candidate discovered by the client during the connection establishment phase. **Served on `agent_url`**, not necessarily the host that served `POST /v1/sessions`. Call this for each candidate emitted by the `RTCPeerConnection.onicecandidate` event, after a successful `POST {agen… - [List webhook endpoints](https://humain.mintlify.app/api-reference/webhooks/list-webhook-endpoints.md) - [Create a webhook endpoint](https://humain.mintlify.app/api-reference/webhooks/create-a-webhook-endpoint.md): Creates a new webhook endpoint. The response includes the signing secret — it is shown only once and cannot be retrieved again. Regenerate it from `POST /api/v1/webhooks/{webhook_id}/regenerate-secret` if lost. - [Get a webhook endpoint](https://humain.mintlify.app/api-reference/webhooks/get-a-webhook-endpoint.md) - [Delete a webhook endpoint](https://humain.mintlify.app/api-reference/webhooks/delete-a-webhook-endpoint.md) - [Update a webhook endpoint](https://humain.mintlify.app/api-reference/webhooks/update-a-webhook-endpoint.md) - [Send a test event](https://humain.mintlify.app/api-reference/webhooks/send-a-test-event.md): Sends a `session.opened` payload with placeholder data to the endpoint, signed with its real secret. Equivalent to the **Send test event** button in the admin panel. - [List recent deliveries](https://humain.mintlify.app/api-reference/webhooks/list-recent-deliveries.md): Returns the most recent delivery attempts for the endpoint, including retries, for debugging failed or delayed webhooks. - [Query session analytics](https://humain.mintlify.app/api-reference/analytics/query-session-analytics.md): Returns session counts, average duration, and completion rate bucketed by day or hour over the requested date range. - [Query usage analytics](https://humain.mintlify.app/api-reference/analytics/query-usage-analytics.md): Returns LLM token, STT minute, and TTS character consumption bucketed by day over the requested date range — useful for cost tracking and plan limit monitoring. - [Changelog](https://humain.mintlify.app/changelog/overview.md): Product updates, new features, and bug fixes for Humain Kiosk. - [Week of July 8, 2026](https://humain.mintlify.app/changelog/2026-07-08.md): Telegram bot, Mini App, and Business connections; Gemini Live voice pipeline; and a corrected session connection model across text, voice, and sandbox. - [Week of May 29, 2026](https://humain.mintlify.app/changelog/2026-05-29.md): Embedded platform support — Raspberry Pi voice, FreeRTOS and Zephyr text/streaming, and an audio hardware selection guide. ## OpenAPI Specs - [openapi](https://humain.mintlify.app/openapi.yaml) This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.