รับข้อมูล Agent

รับข้อมูล Agent

ดึงข้อมูลพื้นฐานของ Agent

วิธีการร้องขอ

GET

URL สำหรับร้องขอ

https://api-${endpoint}.gptbots.ai/v1/bot/detail

การยืนยันตัวตนในการร้องขอ

โปรดดูรายละเอียดการยืนยันตัวตนได้ที่ Overview

การร้องขอ

ตัวอย่างการร้องขอ

curl -X GET 'https://api-${endpoint}.gptbots.ai/v1/bot/detail' \ -H 'Authorization: Bearer ${API Key}'
                      
                      curl -X GET 'https://api-${endpoint}.gptbots.ai/v1/bot/detail' \
-H 'Authorization: Bearer ${API Key}' 

                    
บล็อกโค้ดนี้ในหน้าต่างลอย

Header สำหรับร้องขอ

ฟิลด์ ประเภท คำอธิบาย
Authorization Bearer ${API Key} ใช้ Authorization: Bearer ${API Key} สำหรับการยืนยันตัวตน รับ API Key ได้จากหน้า API Key

พารามิเตอร์สำหรับร้องขอ

ไม่มี

การตอบกลับ

ตัวอย่างการตอบกลับ

{ "bot_id": "645dd86606931c4a9e0ffb1e", "name": "Conversational App", "logo": "https://res.gptbots.ai/ailab/images/default_avatar.png", "bot_type": "QuestionAnswer", "welcome_message": "ข้อความต้อนรับเมื่อผู้ใช้ใช้งานครั้งแรก", "introduction": "แนะนำ Agent", "tags": "แท็กของ Agent", "identity_prompt": "ข้อความแนะนำตัวของ Agent", "creativity_level": 0.3, "doc_correlation": 0.2, "irrelevant_questions": true, "question_limit": 100, "long_term_memory": true }
                      
                      {
  "bot_id": "645dd86606931c4a9e0ffb1e",
  "name": "Conversational App",
  "logo": "https://res.gptbots.ai/ailab/images/default_avatar.png",
  "bot_type": "QuestionAnswer",
  "welcome_message": "ข้อความต้อนรับเมื่อผู้ใช้ใช้งานครั้งแรก",
  "introduction": "แนะนำ Agent",
  "tags": "แท็กของ Agent",
  "identity_prompt": "ข้อความแนะนำตัวของ Agent",
  "creativity_level": 0.3,
  "doc_correlation": 0.2,
  "irrelevant_questions": true,
  "question_limit": 100,
  "long_term_memory": true
}

                    
บล็อกโค้ดนี้ในหน้าต่างลอย

การตอบกลับเมื่อสำเร็จ

ฟิลด์ ประเภท คำอธิบาย
bot_id string รหัส Agent
name string ชื่อ Agent
logo string อวาตาร์ของ Agent
bot_type string ประเภท Agent ค่าที่รองรับ: QuestionAnswer, Flow
welcome_message string ข้อความต้อนรับเมื่อผู้ใช้ใช้งาน Agent ครั้งแรก
introduction string ข้อมูลแนะนำ Agent
tags array แท็กของ Agent
identity_prompt string ข้อความแนะนำตัวของ Agent
creativity_level float ระดับความคิดสร้างสรรค์ (ค่า 0-1)
doc_correlation float ความสอดคล้องกับเอกสาร (ค่า 0-1)
irrelevant_questions boolean ตอบคำถามที่ไม่เกี่ยวข้องกับชุดข้อมูลหรือไม่ (true, false)
question_limit int จำกัดความยาว Token ของคำถามผู้ใช้
long_term_memory boolean เปิดใช้งานหน่วยความจำระยะยาวหรือไม่

การตอบกลับเมื่อผิดพลาด

ฟิลด์ ประเภท คำอธิบาย
code int รหัสข้อผิดพลาด
message string รายละเอียดข้อผิดพลาด

รหัสข้อผิดพลาด

รหัส ข้อความ
40127 การยืนยันตัวตนของนักพัฒนาไม่สำเร็จ
20059 Agent ถูกลบ