Questions
Ask Question
Endpoint:
POST /questions/askDescription: Ask a question about a specific document or knowledge base.
Request Body:
query: The question text.documentIdorkb_id: The ID of the document or knowledge base to query.
Response: Answer object containing the answer to the question.
curl -X POST \
-H "Authorization: Bearer your_api_key_here" \
-H "Content-Type: application/json" \
-d '{"query": "What is the main conclusion?", "documentId": "abc123"}' \
https://api.pagepeek.com/v1/questions/ask{
"question": "What is the main conclusion?",
"answer": "The main conclusion is that...",
"documentId": "abc123"
}Get Question History
Endpoint:
GET /questions/historyDescription: Retrieve the history of questions asked by the user.
Response: Array of question objects containing question and answer history.
curl -X GET \
-H "Authorization: Bearer your_api_key_here" \
https://api.pagepeek.com/v1/questions/history[
{
"question": "What is the main conclusion?",
"answer": "The main conclusion is that...",
"documentId": "abc123",
"timestamp": "2023-10-01T12:00:00Z"
},
// ...other questions
]Last updated