addQuiz
Adds a quiz with the specified content to account of the user associated to the provided access token.
Authentication
Authentication required : an API access token must be provided in the URL query string.
Request
Bold red : required parameter, Bold orange : at least one of parameters required, black : optional parameter.
HTTP Request
POST https://api.jelevelamain.fr/addQuiz?apiKey=API_KEY&accessToken=ACCESS_TOKEN
Parameters
Each parameter is a field of an object which JSON representation is added to the request body.
quiz
|
Type : JSON
|
The partial JSON representation of a Quiz:
{
"title" : string,
"visibility" : string,
"survey" : boolean,
"tags" : string[],
("questions" : Question[],)
("defaultDuration" : string)
("favorite" : boolean)
}
Only the fields listed above will be taken into account (other will be ignored). See the Quiz for a detailed description of constraints on each field.
|
Response
The new Quiz on success, or a JllmAPIException on error. In particular :
- A BadParameterException if one of the required quiz properties is missing or violates a contraint (e.g. invalid type or content).
- A UnauthorizedOperationException if the requesting user does not have the appropriate permission(s) to add a quiz with the specified properties (e.g. "private" visibility).
Try it !
You can test this request on live data and see the API response by filling the form below.
Bold red : required parameter, Bold orange : at least one of parameters required, black : optional parameter.
quiz
|