Skip to content

Edit Classes

Endpoint used to change the code and title of a class, as well as associate it with groups, subgroups, and specialties in Toolzz LMS.

Warning: This endpoint will only work correctly if the domain of your institution is manually provided in the URL. Otherwise, the endpoint may fail or return a validation error.

Terminal window
curl --request PUT \
--url 'https://{your-institution-domain}/api/v1/schools/{schoolId}/classrooms/{classroomId}' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"title": "<string>",
"code": "<string>",
"type": "FILTER",
"group": [1, 2],
"subgroups": [1],
"specialties": [1]
}'
{
"success": true,
"data": {
"id": 1,
"schoolId": "<string>",
"title": "<string>",
"code": "<string>",
"image": null,
"course": null,
"group": [{ "id": 1, "name": "<string>" }],
"subgroups": [{ "id": 1, "name": "<string>" }],
"specialties": [{ "id": 1, "name": "<string>" }],
"trails": [],
"contents": [],
"createdAt": "<string>",
"updatedAt": "<string>"
}
}

ParameterTypeDescriptionRequired
AuthorizationStringAccess token (“Bearer” must be before the token)Yes
ParameterTypeDescriptionRequired
schoolIdstringIdentifier of the school to which the class to be edited is associated.Yes
classroomIdstringIdentifier of the class to be edited.No
ParameterTypeDescriptionRequired
titlestringClass title.No
codestringClass code.No
typeenumType of class to be edited. FILTER: standard platform class, related to exclusive content with the same filters. EXCLUSIVE_CONTENT.No
grouparrayID of one or more institution groups to be linked to the class.No
subgroupsarrayID of one or more institution subgroups to be linked to the class.No
specialtiesarrayID of one or more institution specialties to be linked to the class.No
contentsarrayContent items associated with the class.No

KeyTypeDescription
successbooleanIndicates if the request was successful.
dataobjectDetails of the edited class.
data.idnumberUnique identifier of the class.
data.schoolIdstringIdentifier of the associated school.
data.titlestringClass title.
data.codestringClass code.
data.imagestringClass image URL (may be null).
data.coursestringName of the associated course (may be null).
data.grouparrayList of groups associated with the class.
data.subgroupsarrayList of subgroups associated with the class.
data.specialtiesarrayList of specialties associated with the class.
data.trailsarrayList of trails associated with the class.
data.contentsarrayList of content items associated with the class.
data.createdAtstringDate and time the class was created.
data.updatedAtstringDate and time the class was last updated.

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.