PATCH /api/v1/online-lesson/{id}/remove-material/{material}

Delete a material/resource from an online lesson. Only admins and lecturers can remove materials.

Path parameters

  • id string Required

    UUID of the online lesson

  • material string Required

    UUID of the material to remove

Responses

  • 200 application/json

    Material removed successfully

  • 400 application/json

    Default bad request error 400 response

    Hide response attributes Show response attributes object
    • message string Required

      Response message

    • error string Required
    • statusCode number Required
  • 403

    Forbidden - Admin or Lecturer role required

  • 404

    Material or online lesson not found

PATCH /api/v1/online-lesson/{id}/remove-material/{material}
curl \
 --request PATCH 'http://localhost:3500/api/v1/online-lesson/123e4567-e89b-12d3-a456-426614174000/remove-material/material-123'
Response examples (200)
{
  "message": "Material removed successfully",
  "success": true,
  "deletedMaterialId": "material-123"
}
Response examples (400)
{
  "message": "string",
  "error": "string",
  "statusCode": 42.0
}