Skip to content

Create Class

Endpoint used to create a class.

Terminal window
curl --request POST \
--url https://kong.api.toolzz.com.br/api/content/course/{course_id}/create_class \
--header 'Content-Type: application/json' \
--data '
{
"title": "<string>",
"description": "<string>",
"duration": 123,
"tag": [
{}
],
"progress_criteria": [
{}
],
"show_title": 123,
"enable_lesson_view": 123,
"scheduled_date": "<string>"
}
'
{
"data": {
"curso_id": "<string>",
"id": "<string>",
"user_id": "<string>",
"titulo": "<string>",
"descricao": "<string>",
"enable_lesson_view": 123,
"duracao": 123,
"liberacao": "<string>",
"requisito": "<string>",
"requisito_id": 123,
"tags": "<string>",
"created_at": "<string>",
"updated_at": "<string>",
"ordem": 123,
"title_visibility": 123,
"description_visibility": 123
}
}

ParameterTypeDescriptionRequired
AuthorizationStringAccess token (“Bearer” must be before the token)Yes
ParameterTypeDescriptionRequired
course_idintCourse ID in which the new class will be registered.Yes
ParameterTypeDescriptionRequired
titlestringClass title. Maximum of 150 characters.Yes
descriptionstringClass content description. Maximum of 255 characters.Yes
durationintTotal class duration time. Maximum of 4 characters.No
tagarrayClassification used to group the class. Each tag can have a maximum of 150 characters.No
progress_criteriaarrayList of class IDs required to unlock the current class. Optional, can be sent as null. The indicated classes must belong to the same course as course_id. If one or more IDs are invalid, they are ignored and only the valid IDs are registered.No
show_titleintDefines if the class title is displayed. To be 1, the institution must have the feature “visitor views package”. Default: 0.No
enable_lesson_viewintDefines if the class can be accessed by guest users. To be 1, the institution must have the feature “visitor views package”. Default: 0.No
scheduled_datedateDate for future release of the class. Expected format: YYYY-MM-DD HH:MM. If null, the class will be considered unscheduled.No

KeyTypeDescription
dataobjectList of configurations.
data.curso_idstringUnique identifier for the course.
data.idstringUnique identifier for the configuration.
data.user_idstringID of the associated user.
data.titulostringTitle of the course.
data.descricaostringDescription of the course.
data.enable_lesson_viewnumberEnable lesson view status.
data.duracaonumberDuration of the course.
data.liberacaoDateRelease date and time for the course.
data.requisitostringPrerequisite for the course.
data.requisito_idnumberID of the prerequisite.
data.tagsstringTags associated with the course.
data.created_atDateDate and time when the course was created.
data.updated_atDateDate and time when the course was last updated.
data.ordemnumberOrder or priority of the course.
data.title_visibilitynumberVisibility status of the title.
data.description_visibilitynumberVisibility status of the description.

To access this endpoint, it is necessary to send a valid access token through the authorization header (Authorization) of the request. Additionally, the API is protected by other security measures to safeguard user data.