Class QuizRequest

java.lang.Object
io.constructor.client.QuizRequest

public class QuizRequest extends Object
Constructor.io Next Quiz and Results Quiz request
  • Constructor Details

    • QuizRequest

      public QuizRequest(String quizId)
      Creates a Next Quiz/Results Quiz request
      Parameters:
      quizId - the id of the quiz to request
  • Method Details

    • setQuizId

      public void setQuizId(String quizId)
      Parameters:
      quizId - the id of the quiz to request
    • getQuizId

      public String getQuizId()
      Returns:
      the id of the quiz to request
    • setSection

      public void setSection(String section)
      Parameters:
      section - the section of the product catalog
    • getSection

      public String getSection()
      Returns:
      the section of the product catalog
    • setAnswers

      public void setAnswers(List<List<String>> answers)
      Parameters:
      answers - the list of answers in the format [ [1,2], [3,4] ] where [1,2] are the selected answers for the first question and [3,4] are the selected answers for the second question
    • getAnswers

      public List<List<String>> getAnswers()
      Returns:
      the list of answers for the quiz
    • setQuizVersionId

      public void setQuizVersionId(String quizVersionId)
      Parameters:
      quizVersionId - The quiz version id will be returned with the first request and it should be passed with subsequent requests. More information can be found: https://docs.constructor.io/rest_api/quiz/using_quizzes/#quiz-versioning
    • getQuizVersionId

      public String getQuizVersionId()
      Returns:
      the quizVersionId. The quiz version id will be returned with the first request and it should be passed with subsequent requests. More information can be found: https://docs.constructor.io/rest_api/quiz/using_quizzes/#quiz-versioning
    • setQuizSessionId

      public void setQuizSessionId(String quizSessionId)
      Parameters:
      quizSessionId - The quiz session id will be returned with the first request, and it should be passed with subsequent requests. More information can be found: https://docs.constructor.io/rest_api/quiz/using_quizzes/#quiz-sessions
    • getQuizSessionId

      public String getQuizSessionId()
      Returns:
      the quizSessionId. The quiz session id will be returned with the first request and it should be passed with subsequent requests. More information can be found: https://docs.constructor.io/rest_api/quiz/using_quizzes/#quiz-sessions