hosting
PATCH /v1/sites/{siteId}/chat-agent
Change the agent's name, personality, brand or the domains it may appear on.
การยืนยันตัวตน
ส่ง API key เป็น bearer token เอนด์พอยต์นี้ไม่ได้ระบุสิทธิ์การใช้งานเฉพาะในข้อกำหนด ดังนั้นควรให้คีย์ของคุณมีสิทธิ์น้อยที่สุดเท่าที่จำเป็นและให้ตรวจสอบจากการตอบกลับแทนที่จะคาดเดา
ปลายทางนี้ไม่ต้องใช้รหัสองค์กร คีย์ของคุณระบุองค์กรที่เป็นเจ้าของอยู่แล้ว และการตอบกลับจะถูกจำกัดขอบเขตไว้เฉพาะองค์กรนั้น
ทดลองใช้เลย
แทนที่สิ่งใดๆ ที่อยู่ภายในวงเล็บแหลมด้วยค่าของคุณเอง และตัวยึดตำแหน่งคีย์ด้วยคีย์จากแดชบอร์ดของคุณ
curl -X PATCH https://api.zinndigital.com/v1/sites/{siteId}/chat-agent \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ }'เข้าสู่ระบบแล้วใช่ไหม คอนโซล API ในแดชบอร์ดของคุณจะเติมรหัสองค์กรจริงและคีย์ของคุณเองโดยอัตโนมัติ และทำการส่งคำขอไปยัง API จริง เพื่อให้คุณเห็นผลลัพธ์ที่เป็นข้อมูลจริง เปิดจุดสิ้นสุดนี้ในคอนโซล API
รายละเอียด
Everything a visitor sees is here — and it is the customer's brand, not ours. ⛔ allowed_origins is a fence, not a preference. The public endpoints answer only for an origin on this list, and an empty list refuses everything: it means "not installed anywhere yet", never "allow anything". Entries are normalised to scheme://host, so pasting a full page address works. monthly_message_cap is checked before each answer, not reconciled afterwards, so it is a real limit on what this agent can spend rather than a report on what it did.
พารามิเตอร์
| ชื่อ | ประเภท | จำเป็นต้องมี | ลักษณะของสิ่งนี้ |
|---|---|---|---|
siteId (path) | Uuid | ใช่ | Site ID (UUIDv7). |
เนื้อหาคำขอ
| ชื่อ | ประเภท | จำเป็นต้องมี | ลักษณะของสิ่งนี้ |
|---|---|---|---|
name | string | ไม่ใช่ | — |
greeting | string | ไม่ใช่ | — |
persona | string | ไม่ใช่ | — |
brand_colour | string | ไม่ใช่ | — |
launcher_position | string<left, right> | ไม่ใช่ | — |
handoff_enabled | boolean | ไม่ใช่ | — |
status | string<active, paused> | ไม่ใช่ | — |
allowed_origins | string[] | ไม่ใช่ | — |
monthly_message_cap | integer | ไม่ใช่ | — |
การตอบกลับ
| ชื่อ | ประเภท | จำเป็นต้องมี | ลักษณะของสิ่งนี้ |
|---|---|---|---|
id | string | ใช่ | — |
site_id | string | ไม่ใช่ | — |
name | string | ใช่ | What the agent calls itself to visitors. The customer's brand, not ours. |
greeting | string | ไม่ใช่ | — |
persona | string | ไม่ใช่ | Free text describing tone and what to say. ⛔ It cannot widen what the agent may read — retrieval decides that before the model sees anything. |
brand_colour | string | ไม่ใช่ | — |
launcher_position | string<left, right> | ไม่ใช่ | — |
status | string<active, paused> | ใช่ | paused stops it answering and keeps everything it has learned, so switching back on is instant rather than a re-index. |
handoff_enabled | boolean | ไม่ใช่ | Offer to pass the visitor to a person when the agent cannot answer. |
public_key | string | ใช่ | Carried in the embed snippet. It identifies the agent and authorises nothing a page's reader could not already do — the fence is allowed_origins. |
allowed_origins | string[] | ใช่ | Origins the public endpoints will answer for. ⛔ Empty refuses everything — it means "not installed yet", never "allow anything". |
monthly_message_cap | integer | ไม่ใช่ | Messages included per calendar month. Checked before each answer. |
messages_this_month | integer | ไม่ใช่ | — |
indexed_chunks | integer | ไม่ใช่ | Passages of the site currently searchable. Zero means it knows nothing yet. |
embed_snippet | string | ไม่ใช่ | The two lines to paste into any website. |
sources | ChatAgentSource[] | ใช่ | — |
ข้อผิดพลาดที่เอนด์พอยต์นี้สามารถส่งกลับได้
401 · 403 · 404 · 422