====== Differences ====== This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
|
api2:adaptive:reviews [2017/10/16 10:41] maries created |
api2:adaptive:reviews [2017/11/28 10:02] (current) maries |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | Next best review | + | As you might have seen [[api2:knowledge_structure:knowledge_node_student|in the Knowledge Node Student paragraph]], you can fetch the dates of the next reviews by fetching the knowledge node students.\\ |
| + | However, it can be cumbersome, and we offer here other solutions. | ||
| + | |||
| + | ===Fetch Reviews (GET)=== | ||
| + | |||
| + | This route will give you the set of Knowledge Node Student which represent the Knowledge Nodes, i.e. the concepts, that are being worked on for review. | ||
| + | |||
| + | ^ Method | GET| | ||
| + | ^ URL | /review_utils/fetch_reviews | | ||
| + | |||
| + | ==Parameters== | ||
| + | ^ Property ^ Type ^ Description ^ | ||
| + | | student_id or student_uid *| Integer or String | Identifier of the student | | ||
| + | | pending | Boolean | if true, only give the pending reviews; if false, give all the reviews (pending plus future ones) | | ||
| + | |||
| + | ==Send the request (JSON input example)== | ||
| + | |||
| + | <code> | ||
| + | { | ||
| + | "student_id": 267, | ||
| + | "pending": true | ||
| + | } | ||
| + | </code> | ||
| + | |||
| + | ==Get the response (JSON output example)== | ||
| + | |||
| + | <code> | ||
| + | [ | ||
| + | { | ||
| + | "id": 759, | ||
| + | "knowledge_node_id": 2714, | ||
| + | "student_id": 267, | ||
| + | "next_review_at": "2017-11-22T09:53:09.621Z", | ||
| + | "student_uid": null, | ||
| + | "knowledge_node_uid": null | ||
| + | }, | ||
| + | { | ||
| + | "id": 760, | ||
| + | "knowledge_node_id": 2715, | ||
| + | "student_id": 267, | ||
| + | "next_review_at": "2017-09-22T14:35:42.009Z", | ||
| + | "student_uid": null, | ||
| + | "knowledge_node_uid": null | ||
| + | }, | ||
| + | { | ||
| + | "id": 761, | ||
| + | "knowledge_node_id": 2716, | ||
| + | "student_id": 267, | ||
| + | "next_review_at": "2017-09-22T14:35:43.288Z", | ||
| + | "student_uid": null, | ||
| + | "knowledge_node_uid": null | ||
| + | } | ||
| + | ] | ||
| + | </code> | ||
| + | |||
| + | ===Fetch Questions for Review (GET)=== | ||
| + | |||
| + | This requires that you declared your content on our API, and defined which contents are questions.\\ | ||
| + | It will give you the questions one student has do to for his/her reviews. | ||
| + | |||
| + | ^ Method | GET| | ||
| + | ^ URL | /review_utils/fetch_pending_reviews_questions_per_student | | ||
| + | |||
| + | ==Parameters== | ||
| + | ^ Property ^ Type ^ Description ^ | ||
| + | | student_id or student_uid *| Integer or String | Identifier of the student | | ||
| + | |||
| + | ==Send the request (JSON input example)== | ||
| + | |||
| + | <code> | ||
| + | { | ||
| + | "student_id": 267 | ||
| + | } | ||
| + | </code> | ||
| + | |||
| + | ==Get the response (JSON output example)== | ||
| + | |||
| + | <code> | ||
| + | [ | ||
| + | { | ||
| + | "knowledge_node_id": 2715, | ||
| + | "content_id": 561, | ||
| + | "content_uid": "5" | ||
| + | }, | ||
| + | { | ||
| + | "knowledge_node_id": 2716, | ||
| + | "content_id": 897, | ||
| + | "content_uid": "63" | ||
| + | }, | ||
| + | { | ||
| + | "knowledge_node_id": 2714, | ||
| + | "content_id": 702, | ||
| + | "content_uid": "30" | ||
| + | } | ||
| + | ] | ||
| + | </code> | ||
| + | |||