Authentifizierung
Senden Sie einen API-Schlüssel als Bearer-Token. Der Schlüssel muss über die Berechtigung livechat.manage verfügen; ein Schlüssel ohne diese wird mit 403 statt 404 abgelehnt.
Hier kommt Ihre Organisations-ID hin
Dieser Endpunkt akzeptiert org_id als Feld im JSON-Body.
Die ID Ihrer Organisation finden Sie im Dashboard auf dem Bildschirm für API-Schlüssel direkt neben dem Schlüssel selbst. Sie ist bei jedem Ihrer Aufrufe dieselbe.
Ausprobieren
Ersetzen Sie alles in spitzen Klammern durch Ihre eigenen Werte und den Platzhalter für den Schlüssel durch einen Schlüssel aus Ihrem Dashboard.
curl -X POST https://api.zinndigital.com/v1/chat/widgets \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "name": <string> }'Angemeldet? Die API-Konsole in Ihrem Dashboard trägt automatisch Ihre echte Organisations-ID sowie Ihren eigenen Schlüssel ein und führt die Anfrage gegen die Live-API aus, sodass Sie die tatsächliche Antwort sehen können. Öffnen Sie diesen Endpunkt in der API-Konsole
Details
Requires `livechat.manage`. The new widget is created **switched off**: a chat window that starts talking to a customer's visitors before they have asked for one is a consent problem, not a feature.
Anfragekörper
| Name | Typ | Erforderlich | Was es ist |
|---|---|---|---|
org_id | string | Nein | — |
site_id | string | Nein | — |
name | string | Ja | — |
team_name | string | Nein | — |
allowed_origins | string[] | Nein | — |
Antwort
| Name | Typ | Erforderlich | Was es ist |
|---|---|---|---|
id | string | Ja | — |
site_id | string | Ja | — |
name | string | Ja | — |
public_key | string | Ja | — |
enabled | boolean | Ja | Whether the chat renders. Created FALSE always: the plugin ships in the deploy footprint of every WordPress site we host, so a widget may exist for a customer who never asked fo… |
allowed_origins | string[] | Ja | Origins the widget may be embedded on. An EMPTY list refuses every page rather than allowing any — this is the only control stopping somebody else's site opening conversations a… |
tier | string | Ja | — |
greeting | string | Ja | — |
team_name | string | Ja | — |
accent_colour | string | Ja | — |
position | string<left, right> | Ja | — |
hide_branding | boolean | Ja | — |
ai_enabled | boolean | Ja | — |
offline_email | string | Ja | — |
business_hours | object | Nein | — |
open_now | boolean | Ja | — |
ai_allowance | ChatAiAllowance | Ja | — |
limits | object | Ja | — |
premium_extra_code | string | Ja | The catalogue code to buy for the premium tier. |
Fehler, die dieser Endpunkt zurückgeben kann
401 · 403 · 422