This repository was archived by the owner on Mar 27, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Home
Haloxx edited this page Jul 6, 2023
·
2 revisions
The Kahoot
class represents a Kahoot quiz and provides methods to interact with the quiz data.
Class: Kahoot
-
uuid
(str): The UUID of the Kahoot quiz. -
data
(dict or False): The loaded data of the Kahoot quiz if successful, or False if unsuccessful.
Initializes a new instance of the Kahoot class.
Parameters:
-
uuid
(str): The UUID of the Kahoot quiz.
-
dict
: The loaded data of the Kahoot quiz.
Retrieves the details of the Kahoot quiz.
Returns:
-
dict
: A dictionary containing the following details:-
uuid
(str): The UUID of the quiz. -
creator_username
(str): The username of the creator. -
title
(str): The title of the quiz. -
description
(str): The description of the quiz. -
cover
(str): The cover image URL of the quiz.
-
Retrieves the questions of the Kahoot quiz.
Returns:
-
list
: A list of dictionaries representing the questions of the quiz.
Retrieves the names of the questions in the Kahoot quiz.
Returns:
-
list
: A list of strings representing the names of the questions.
Retrieves the number of questions in the Kahoot quiz.
Returns:
-
int
: The number of questions in the quiz.
Retrieves the details of a specific question in the Kahoot quiz.
Parameters:
-
question
(int): The index of the question.
Returns:
-
dict
: A dictionary containing the details of the question.
Retrieves the answer(s) of a specific question in the Kahoot quiz.
Parameters:
-
question
(int): The index of the question.
Returns:
-
list
orNone
: A list of answers if the question is not a content question, orNone
if it is a content question.