Get Q&A List
Última actualización:
Get Q&A List
Get the Q&A list from the Bot chat history.
Request Method
GET
Request URL
https://api.gptbots.ai/v1/message/qa/record/page
Request Authentication
See Overview for authentication details.
Request
Request Example
curl --location 'https://api.gptbots.ai/v1/message/qa/record/page?page=1&page_size=10&start_time=1732982400000&end_time=1735660799999&user_feedback=ALL' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json'
curl --location 'https://api.gptbots.ai/v1/message/qa/record/page?page=1&page_size=10&start_time=1732982400000&end_time=1735660799999&user_feedback=ALL' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json'
Este bloque de código en la ventana flotante
Request Header
Field | Type | Description |
---|---|---|
Authorization | Bearer ${token} | Use Authorization: Bearer ${token} for authentication. Get the key from the API Keys page as token. |
Content-Type | application/json | Data type, set to application/json . |
Request Body
Field | Type | Required | Description |
---|---|---|---|
user_feedback | String | Yes | User feedback. |
start_time | Long | Yes | The start time of the query range, in timestamp format. The query object is the time of the questions (Q) in QA. |
end_time | Long | Yes | The end time of the query range, in timestamp format. The query object is the time of the questions (Q) in QA. |
page | Integer | Yes | Page number, starting from 1. |
page_size | Integer | Yes | Number of documents per page. Fill in the range of 10-100. |
Response
Response Example
{
"qa": [
{
"id": "xxxxxx",
"q_time": 1699891200,
"q": "xxxxxx",
"a": "xxxxxx",
"user_feedback": "GOOD",
"convo_id": "xxxxxx",
"convo_type": "API",
"aid": "xxxxxx",
"user_id": "xxxxxx"
},
{
"id": "xxxxxx",
"q_time": 1699891214,
"q": "xxxxxx",
"a": "xxxxxx",
"user_feedback": "BAD",
"convo_id": "xxxxxx",
"convo_type": "API",
"aid": "xxxxxx",
"user_id": "xxxxxx"
}
]
}
{
"qa": [
{
"id": "xxxxxx",
"q_time": 1699891200,
"q": "xxxxxx",
"a": "xxxxxx",
"user_feedback": "GOOD",
"convo_id": "xxxxxx",
"convo_type": "API",
"aid": "xxxxxx",
"user_id": "xxxxxx"
},
{
"id": "xxxxxx",
"q_time": 1699891214,
"q": "xxxxxx",
"a": "xxxxxx",
"user_feedback": "BAD",
"convo_id": "xxxxxx",
"convo_type": "API",
"aid": "xxxxxx",
"user_id": "xxxxxx"
}
]
}
Este bloque de código en la ventana flotante
Success Response
Field Name | Type | Description |
---|---|---|
qa | Array | List of Q&A. |
id | String | ID of the Q&A. |
q_time | Long | Timestamp of when the question (Q) was issued. |
q | String | Content of the question. |
a | String | Content of the answer. |
user_feedback | String | User feedback. |
convo_id | String | ID of the associated conversation. |
convo_type | String | Type of the associated conversation. |
user_id | String | User ID. A custom ID marked by the bot developer through third-party means, used to identify the specific identity of the user. |
Failure Response
Field | Type | Description |
---|---|---|
code | Int | Error code. |
message | String | Error details. |