Create generatePaper API
Requires fixing #12, The generatePaper API accepts question paper contstrains from the user, generates a question paper and returns it.
(Proposed) Parameters/Constraints
marksdifficultyclubQuestions- BooleanoptionalQuestions- BooleansavePreset- Booleantopics: ObjectArray{ topics: (Relational to topic model, its slug should be accepted), min_marks: int, max_marks: int, optional: boolean (default false) }types: ObjectArray{ types: (Relational to type model, its slug should be accepted), min_marks: int, max_marks: int } [ Optional ]sections: ObjArray{ title: string, marks: int types: (Relational to type model, its slug should be accepted), topics: (Relational to topic model, its slug should be accepted), difficulty:[enum] }
(Proposed) Return
-> Return QuestionPaper Obj ID [ which can be queried using another API to get the question paper in required form].
The logic of question paper generation can be implemented separately, essentially this issue is only to handle the API and send required params to the generator script (assuming one exists).
@aswinshenoy, I am trying to add relation for types and sections parameters and also enum type for difficulty constraint under sections parameters, but I cannot able to put it in schema file. How should I approach?