Appearance
Troubleshooting
Start with the browser's developer tools: the Console shows the chat's own messages (prefixed [Wireface Chat], with a link to the error's explanation), and the Network tab shows its requests. Booting with debug: true (or data-debug="true") logs every event the chat emits.
js
WirefaceChat.getState(); // { open, conversationId, visitorId, unread }The chat doesn't appear
Work through these in order:
- Is widget.js loading? In the Network tab,
widget.jsshould answer 200. A 404 with "widget.js is not built yet" means the server was started without building the widget. - Does the bot load? Look for
/v1/widget/bots/<id>/config: - Is it hidden?
launcher: { type: 'none' }orhideOnMobilehide the launcher; another element with a higherz-indexcan cover it (raise the chat'szIndex). - Inline layout? The
targetelement must exist when the chat starts; if it doesn't, the console says so and the chat falls back to a launcher.
"This website is not allowed to use this chat"
origin_not_allowed: the page's origin isn't in the bot's allowed origins.
- Add the exact origin under the bot's Security tab and publish: scheme, host and port must all match (
https://www.example.comis nothttps://example.com). https://*.example.comcovers subdomains but not the bare domain; add both if you use both.- For local testing add
http://localhost:*. - A page inside another site's iframe also fails: every page up the frame chain must be allowed (the chat window's
frame-ancestors). That shows asframe_blocked.
Content-Security-Policy violations
The console names the directive. Add your chat host to:
script-src(widget.js),connect-src(the bot's settings),frame-src(the chat window) andimg-src(the face on the launcher).
Symptoms: network when connect-src blocks the settings request; frame_blocked 15 seconds after opening when frame-src blocks the window. With the npm package under enforced Trusted Types, allow its policy: trusted-types wireface-chat. See Content-Security-Policy.
No sound
- Browsers only play sound after the visitor interacts with the page. Voice started from the chat's microphone button always works; see Voice.
- Text replies are silent: only voice conversations speak. (The face moves its lips to text replies, without sound.)
- Check the device's volume and that the tab isn't muted.
Microphone and camera
mic_denied, mic_unavailable, camera_denied:
- HTTPS. Both your site and the chat server must be
https://(localhostis fine for testing). On plainhttpthe browser never offers the microphone. - Permission. If the visitor blocked it once, the browser remembers: they can allow it again from the icon in the address bar.
- Permissions-Policy. If your site sends a
Permissions-Policyheader, it must delegatemicrophoneandcamerato the chat host:microphone=(self "https://chat.example.com"). See CSP. - Another app using the microphone or camera, or no device at all, gives
mic_unavailableorcamera_deniedwith the browser's own reason. - The camera button only shows when the bot's camera is enabled and its brain can see images.
The face looks different, or doesn't move
The full animated face needs WebGL2. Without it (very old devices, some virtual machines, or hardware acceleration turned off in the browser) the chat draws a lighter 2D wireframe of the face instead, and if even that can't load, a still picture; everything else works. Turning hardware acceleration back on in the browser's settings usually brings the full face back. (The webgl_unavailable code is reserved and not raised.)
Visitors who ask their system for reduced motion get a calmer face on purpose.
The chat keeps reconnecting
The header says "Reconnecting..." and messages don't send: the chat window's WebSocket (/v1/widget/ws) isn't getting through.
- A reverse proxy must pass WebSocket upgrades (
UpgradeandConnectionheaders). See Reverse proxy. - 403 on the socket ("Open the chat through its frame"): the server compares the chat's origin with its own address. Set
PUBLIC_URLto the exact public address, andTRUST_PROXY=truebehind a proxy. - Corporate networks and some antivirus software block WebSockets; there's no fallback transport in this version.
- After a fatal error (an origin or identity problem, or too many connections from one address) the chat stops trying until the page is reloaded.
Voice unavailable or busy
voice_unavailable: voice isn't fully set up for the bot (the Voice tab lists what's missing), a person from your team has the chat, or the voice engine stopped with an error (the message says which).voice_capacity: the bot hassecurity.caps.concurrentVoiceSessionsvoice conversations already.spend_cap_reached: a daily cap (security.caps) is used up; it resets at midnight UTC.- No microphone button at all: voice is off, or its engine isn't fully configured (a missing connection, model or voice).
Provider key errors
The visitor sees "Sorry, I couldn't answer just now" and the admin panel marks the connection.
invalid: the provider rejected the key (revoked, mistyped, or for another project). Replace it under Providers.quota: the account is out of credit or over its spending limit at the provider.error: the server couldn't reach the provider: check outbound internet access, a corporate proxy, or thePROVIDER_BASE_URL_*variables.- A model that disappeared from your account: pick another in the bot's Brain or Voice tab and publish.
- Test on the connection checks the key again. The server log has the provider's own error message.
In previews, the chat itself shows why a reply failed.
"No one from the team is available"
A hand-off needs someone who can take it: within the bot's opening hours (when it has them), and someone from the team (an owner, admin or agent) with the admin panel open, so their presence is online or away. Presence resets to offline when the server restarts, until their panel reconnects. See Human handoff.
The agent doesn't use my page tools
- Client tools are off by default: turn on
tools.client.enabledand list the tool names intools.client.allow(or*) in the bot's Tools tab, then publish. - The tool must be registered on the page the visitor is on.
- Make the description say when to use it. See Client tools.
Identity errors
identity_required: the bot requires identity and the page sent nouser. Pass it toboot().identity_invalid: the hash doesn't match. Hash exactly theidstring you pass, with the bot's current identity secret, on your server. It also comes when a different user is signed in to a chat a verified user already has: callshutdown({ forget: true })on sign-out. See Identity verification.
Still stuck?
Set LOG_LEVEL=debug on the server and reproduce the problem: the log shows each step. The error codes and what causes each are listed in Errors.