GET questions/singlerandom?difficulty={difficulty}&allDifficulties={allDifficulties}&fineGrainedDifficulty={fineGrainedDifficulty}&usedQuestions={usedQuestions}
Convenience api call to get a single random question. User Authorization Optional.
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| difficulty |
Qptional question difficulty querystring parameter (1-4). |
integer |
Default value is 0 |
| allDifficulties |
return all difficulties if true. default false. |
boolean |
Default value is False |
| fineGrainedDifficulty |
select by fine grained difficulty (1-100). default 0 (not fine grained) |
integer |
Default value is 0 |
| usedQuestions |
Comma seperated question ids that have been used. |
string |
Default value is |
Body Parameters
None.
Response Information
Resource Description
Single question.
ResponseInstanceOfQuestionAndAnswer| Name | Description | Type | Additional information |
|---|---|---|---|
| Data | QuestionAndAnswer |
None. |
|
| ResultType | ResultType |
None. |
|
| Messages | Collection of string |
None. |
|
| Links | Links |
None. |
|
| ApiBaseUrl | string |
None. |
|
| responseObjectType | string |
None. |
Response Formats
application/json, text/json
Sample:
{
"data": {
"questionId": 1,
"category": {
"categoryId": 1,
"categoryName": "sample string 2",
"seoName": "sample string 3",
"questions": 4,
"sortOrder": 5,
"apiUrl": {
"href": "/categories/sample string 8"
},
"resourceObjectType": "category"
},
"question": "sample string 2",
"choice1": "sample string 3",
"choice2": "sample string 4",
"choice3": "sample string 5",
"choice4": "sample string 6",
"choices": [
"sample string 1",
"sample string 2"
],
"answer": 7,
"book": {
"bookId": 1,
"bookName": "sample string 2",
"chapterCount": 3,
"apiUrl": {
"href": "/books/sample string 5"
},
"resourceObjectType": "book"
},
"chapter": 8,
"startVerse": 9,
"endVerse": 10,
"difficulty": 11,
"bibleReference": "sample string 12",
"bibleReferenceText": "sample string 13",
"apiUrl": {
"href": "/questions/sample string 16"
},
"resourceObjectType": "questionAndAnswer"
},
"resultType": {
"code": 0,
"message": "Success"
},
"messages": [
"sample string 1",
"sample string 2"
],
"links": {},
"apiBaseUrl": "sample string 1",
"responseObjectType": "responseInstance<questionAndAnswer>"
}
application/xml, text/xml
Sample:
<ResponseInstance xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<ApiBaseUrl>sample string 1</ApiBaseUrl>
<Links>
<First i:nil="true" />
<Last i:nil="true" />
<Next i:nil="true" />
<Previous i:nil="true" />
<Self i:nil="true" />
</Links>
<Messages xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d2p1:string>sample string 1</d2p1:string>
<d2p1:string>sample string 2</d2p1:string>
</Messages>
<ResultType>
<Code>Success</Code>
<Message>Success</Message>
</ResultType>
<responseObjectType>responseInstance<questionAndAnswer></responseObjectType>
<Data>
<ApiUrl>
<href>/questions/sample string 16</href>
</ApiUrl>
<ResourceObjectType>questionAndAnswer</ResourceObjectType>
<Answer>7</Answer>
<BibleReference>sample string 12</BibleReference>
<BibleReferenceText>sample string 13</BibleReferenceText>
<Book>
<ApiUrl>
<href>/books/sample string 5</href>
</ApiUrl>
<ResourceObjectType>book</ResourceObjectType>
<BookId>1</BookId>
<BookName>sample string 2</BookName>
<ChapterCount>3</ChapterCount>
</Book>
<Category>
<ApiUrl>
<href>/categories/sample string 8</href>
</ApiUrl>
<ResourceObjectType>category</ResourceObjectType>
<CategoryGroup i:nil="true" />
<CategoryId>1</CategoryId>
<CategoryName>sample string 2</CategoryName>
<Questions>4</Questions>
<SeoName>sample string 3</SeoName>
<SortOrder>5</SortOrder>
</Category>
<Chapter>8</Chapter>
<Choice1>sample string 3</Choice1>
<Choice2>sample string 4</Choice2>
<Choice3>sample string 5</Choice3>
<Choice4>sample string 6</Choice4>
<Choices xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d3p1:string>sample string 1</d3p1:string>
<d3p1:string>sample string 2</d3p1:string>
</Choices>
<Difficulty>11</Difficulty>
<EndVerse>10</EndVerse>
<Question>sample string 2</Question>
<QuestionId>1</QuestionId>
<StartVerse>9</StartVerse>
</Data>
</ResponseInstance>