深宇识
用户7226
添加快捷方式
分享
Copilot Hub Open API Access Doc
输入“/”快速插入内容
Copilot
Hub
Open
API
Access Doc
Workflow
1.
Create
a Copilot on
Copilot Hub
.
2.
Get
the
API
key
from
Integration
module of Copilot Dashboard
.
3.
Use our
API
Endpoint to integrate corresponding Copilot into your own apps
API
Endpoint
Use
https://api.copilothub.ai/
openapi/v1/query
to call our copilot service for
query
代码块
Bash
curl --location --request POST '
https://api.copilothub.ai/
openapi/v1/query' \
--header 'Content-Type: application/json' \
--data-raw '{
"api_key":"XXX",
"query":"Hello"
}'
Method:POST
Body
Response
Example:
代码块
JSON
{
"result": "Hello! How can I assist you today?",
"sources": [
"2304.01852.pdf"
],
"quota": 798,
"default_quota": 800,
"package_quota": 100
}
Error Status Code