Retrieve questions by offset and limit
Retrieve questions by offset and limit
Query Parameters
- offset number required
The offset of the question
- limit number required
The limit of the question
- 200
Returns an array of questions.
- application/json
- Schema
- Example (from schema)
Schema
- Array [
questions object[] required
Array of questions
Array [id number requiredUnique identifier for the question
user object
id number requiredUnique identifier for the user
username string requiredUsername of the user
role string requiredRole of the user (e.g., admin, user)
questionText string requiredText content of the question
category object
id numberUnique identifier for the category
name stringName of the category
description stringDescription of the category
questionType object
id number requiredUnique identifier for the question type
name string requiredName of the question type
question_image string requiredImage associated with the question, if any
explanation string requiredExplanation or answer to the question
difficulty_level string requiredDifficulty level of the question
verified number requiredVerification status of the question
flagged number requiredFlag status of the question
votes number requiredNumber of votes the question has received
numberOfAnswers number requiredNumber of answers the question has received
userVote string requiredPossible values: [
up
,down
,null
]Vote status by the current user
created_at date-time requiredDate when the question was created
updated_at date-time requiredDate when the question was last updated
]- totalCount number required
Total number of questions
- ]
[
{
"questions": [
{
"id": 0,
"user": {
"id": 0,
"username": "string",
"role": "string"
},
"questionText": "string",
"category": {
"id": 0,
"name": "string",
"description": "string"
},
"questionType": {
"id": 0,
"name": "string"
},
"question_image": "string",
"explanation": "string",
"difficulty_level": "string",
"verified": 0,
"flagged": 0,
"votes": 0,
"numberOfAnswers": 0,
"userVote": "up",
"created_at": "2024-07-21T21:27:58.757Z",
"updated_at": "2024-07-21T21:27:58.757Z"
}
],
"totalCount": 0
}
]