logo
開發者文件
搜尋
智能代理回饋評估

智能代理回饋評估

協助開發與營運人員檢查並評估智能代理生成內容的品質,協助評量回應品質並指引進一步優化。

請求方法

POST

端點

https://api-${endpoint}.gptbots.ai/v1/message/quality

認證

請參閱API 概述了解認證說明。

請求

請求範例

curl -X POST 'https://api-${endpoint}.gptbots.ai/v1/message/quality' \ -H 'Authorization: Bearer ${API Key}' \ -H 'Content-Type: application/json' \ -d '{ "answer_id": "123456789", "quality": "FULLY_RESOLVED" }'
                      
                      curl -X POST 'https://api-${endpoint}.gptbots.ai/v1/message/quality' \
-H 'Authorization: Bearer ${API Key}' \
-H 'Content-Type: application/json' \
-d '{
        "answer_id": "123456789",
        "quality": "FULLY_RESOLVED"
}'

                    
此代碼塊在浮窗中顯示

請求標頭

欄位 類型 描述
Authorization Bearer ${API Key} 您可從 API Key 頁面取得 API 金鑰,並使用 Authorization: Bearer ${API Key} 進行認證。
Content-Type application/json 資料類型,值應為 application/json。

請求參數

欄位 類型 必填 描述
answer_id string 回覆 ID。
quality string 智能代理回應的品質保證評估。可選值:
- NONE: 無反饋
- UNRESOLVED: 未解決
- PARTIALLY_RESOLVED: 部分解決
- FULLY_RESOLVED: 完全解決

回應

回應範例

{ "affectCount": 2 }
                      
                      {
    "affectCount": 2
}

                    
此代碼塊在浮窗中顯示

成功回應

欄位 類型 描述
affectCount long 此次評估成功的數量。值為 2 表示成功。

錯誤回應

欄位 類型 描述
code int 錯誤代碼
message string 錯誤詳細資訊

錯誤代碼

代碼 訊息
40000 參數錯誤
40127 開發者認證失敗
20059 智能代理已被刪除