-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapi_desc.txt
More file actions
96 lines (95 loc) · 2.48 KB
/
api_desc.txt
File metadata and controls
96 lines (95 loc) · 2.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
GET /
{
"source": "Nexian-knowledgeAPI",
"version": 0.5,
"sent-on": "2020-02-26 18:13:30.887193",
"message": {
"level": "info",
"data": "Let's absorb some knowledge"
}
}
----
GET /quiz
( GET /quiz/<string:uuid>/ )
?data = {
"nodes":
[
{"identifier": 1,"information":"a is c"},
{"identifier": 2,"information":"a is b"},
{"identifier":3,"information":"b is c"}
],
"parents_to_children":{ "1": [2, 3],
"2": [],
"3": []}
}
{
"source": "Nexian-knowledgeAPI",
"version": 0.5,
"sent-on": "2020-02-26 18:38:01.606373",
"message": {
"level": "info",
"data": {
"quiz-session": {
"uuid": "a764e9fc",
"started_on": "2020-02-26 18:38:01.606373",
"finished": false,
"knowledges": [
{
"timestamp": "2020-02-26 18:38:01.606373",
"identifier": 1,
"information": "a is c",
"parents": [],
"children": [
2,
3
]
},
{
"timestamp": "2020-02-26 18:38:01.606373",
"identifier": 2,
"information": "a is b",
"parents": [
1
],
"children": []
},
{
"timestamp": "2020-02-26 18:38:01.606373",
"identifier": 3,
"information": "b is c",
"parents": [
1
],
"children": []
}
]
}
}
}
}
----
GET /quiz/<string:uuid>/next-question
{
"source": "Nexian-knowledgeAPI",
"version": 0.5,
"sent-on": "2020-02-26 18:43:18.568413",
"message": {
"level": "info",
"data": "a is ..."
}
}
---
PUT /quiz/3f38b608/next-question?answer=twentyone
{
"source": "Nexian-knowledgeAPI",
"version": 0.5,
"sent-on": "2020-02-26 18:44:08.095813",
"message": {
"level": "info",
"data": {
"correct": false,
"given-answer": "twentyone"
}
}
}
---