live-chat
GET /v1/chat/widgets/{widgetId}
One chat's settings and its AI allowance.
Xác thực
Gửi khóa API dưới dạng mã thông báo bearer. Khóa này phải có quyền livechat.view; khóa không có quyền này sẽ bị từ chối với mã lỗi 403, không phải 404.
Endpoint này không nhận ID tổ chức. Khóa của bạn đã xác định tổ chức mà nó thuộc về và phản hồi được giới hạn trong phạm vi đó.
Dùng thử
Thay thế bất kỳ nội dung nào trong ngoعل (angle brackets) bằng giá trị của riêng bạn và trình giữ chỗ key bằng một key từ trang tổng quan của bạn.
curl -X GET https://api.zinndigital.com/v1/chat/widgets/{widgetId} \
-H "Authorization: Bearer zdk_live_…"Đã đăng nhập? Bảng điều khiển API trong trang quản lý của bạn sẽ tự điền ID tổ chức thực tế và khóa của riêng bạn, sau đó chạy yêu cầu đối với API trực tiếp để bạn có thể xem phản hồi thực tế. Mở điểm cuối này trong bảng điều khiển API
Chi tiết
Requires livechat.view or livechat.manage.
Tham số
| Tên | Loại | Bắt buộc | Nội dung này là gì |
|---|---|---|---|
widgetId (path) | string | Có | — |
Phản hồi
| Tên | Loại | Bắt buộc | Nội dung này là gì |
|---|---|---|---|
id | string | Có | — |
site_id | string | Có | — |
name | string | Có | — |
public_key | string | Có | — |
enabled | boolean | Có | 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 for… |
allowed_origins | string[] | Có | 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… |
tier | string | Có | The tier this widget is EFFECTIVELY on. Premium is included free with Zinn® hosting, so this may read premium on a widget nobody has paid for — read purchased_tier for what… |
tier_source | string<free, purchase, hosting> | Có | Why the widget is on that tier. hosting means it is included with the customer's Zinn® hosting and there is nothing to buy; purchase means the Premium extra was bought for… |
purchased_tier | string | Có | The tier actually PAID for, independent of any hosting inclusion. |
greeting | string | Có | — |
team_name | string | Có | — |
accent_colour | string | Có | — |
position | string<left, right> | Có | — |
hide_branding | boolean | Có | — |
ai_enabled | boolean | Có | — |
offline_email | string | Có | — |
business_hours | object | Không | — |
open_now | boolean | Có | — |
ai_allowance | ChatAiAllowance | Có | — |
limits | object | Có | — |
premium_extra_code | string | Có | The catalogue code to buy for the premium tier. |
Các lỗi điểm cuối này có thể trả về
401 · 403 · 404