offset integer >= 0
Default: 0
The number of items to skip before starting to collect the result set
+
put /videos/{token}/playlists
https://demo.studip.de/plugins.php/opencast/api /videos/{token}/playlists
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Set playlist link Set playlist links for the video with the passed token, clearing out all not passed playlist links.
+
Responses 200 successful operation
+get /videos/{token}/shares
https://demo.studip.de/plugins.php/opencast/api /videos/{token}/shares
Response samples Content type application/json
Copy
Expand all Collapse all { "perms" :
{ "video_id" : "string" ,
"user_id" : "string" ,
"perm" : "string" ,
"id" : "string" ,
"fullname" : "string"
} , "shares" :
{ "token" : "string" ,
"video_id" : "string" ,
"uuid" : "string" ,
"id" : "string" ,
"link" : "string"
} }
Set playlist link Set playlist links for the video with the passed token, clearing out all not passed playlist links.
+
Request Body schema: application/json List of courses to link to
+
Responses 200 successful operation
+put /videos/{token}/shares
https://demo.studip.de/plugins.php/opencast/api /videos/{token}/shares
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Copy
Expand all Collapse all { "perms" :
{ "video_id" : "string" ,
"user_id" : "string" ,
"perm" : "string" ,
"id" : "string" ,
"fullname" : "string"
} , "shares" :
{ "token" : "string" ,
"video_id" : "string" ,
"uuid" : "string" ,
"id" : "string" ,
"link" : "string"
} }
Connect all playlists for the ourse in the path to the courses posted in the body path Parameters course_id required
string
ID of the course to copy from
+
Request Body schema: */* List of courses to connect the playlists to
+
Responses 200 successful operation
+post /videos/{course_id}/copy
https://demo.studip.de/plugins.php/opencast/api /videos/{course_id}/copy
Response samples Content type application/json
Get the playlists for the session user query Parameters offset integer >= 0
Default: 0
The number of items to skip before starting to collect the result set
limit integer >= 20
Default: 20
The numbers of items to return
Responses 200 successful operation
-get /playlists
https://demo.studip.de/plugins.php/opencast/api /playlists
Response samples Content type application/json
Copy
Expand all Collapse all [ { "title" : "Meine Videos" ,
"description" : "string" ,
"visibility" : "internal" ,
"mkdate" : "2019-08-24T14:15:22Z" ,
"chdate" : "2019-08-24T14:15:22Z" ,
"references" :
[ { "course_id" : "string" ,
"visibility" : "hidden"
} ] } ]
Add a new playlist for the current user Request Body schema: */* Playlist object to be added for the current user
+
get /playlists
https://demo.studip.de/plugins.php/opencast/api /playlists
Response samples Content type application/json
Copy
Expand all Collapse all [ { "title" : "Meine Videos" ,
"description" : "string" ,
"visibility" : "internal" ,
"mkdate" : "2019-08-24T14:15:22Z" ,
"chdate" : "2019-08-24T14:15:22Z" ,
"references" :
[ { "course_id" : "string" ,
"visibility" : "hidden"
} ] } ]
Add a new playlist for the current user Request Body schema: */* Playlist object to be added for the current user
title required
description visibility string
Enum: "internal" "free" "public"
mkdate chdate references Array of objects (PlaylistReference)
Responses 200 successful operation
-post /playlists
https://demo.studip.de/plugins.php/opencast/api /playlists
Response samples Content type application/json
Get the playlist with the passed id path Parameters token required
post /playlists
https://demo.studip.de/plugins.php/opencast/api /playlists
Response samples Content type application/json
Get the playlist with the passed id Responses 200 successful operation
-get /playlists/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}
Response samples Content type application/json
Update the playlist with the passed id path Parameters token required
get /playlists/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}
Response samples Content type application/json
Update the playlist with the passed id Request Body schema: */* Playlist object to be updated
title required
description visibility string
Enum: "internal" "free" "public"
mkdate chdate references Array of objects (PlaylistReference)
Responses 200 successful operation
-put /playlists/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}
Response samples Content type application/json
Delete the playlist with the passed id (if current user has permissions to do so) path Parameters token required
put /playlists/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}
Response samples Content type application/json
Delete the playlist with the passed id (if current user has permissions to do so) delete /playlists/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}
Add video to playlist path Parameters token required
string
token reference for playlist or video
Responses 200 successful operation
-put /playlists/{token}/video/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/video/{token}
Response samples Content type application/json
Delete video from playlist path Parameters token required
string
token reference for playlist or video
+
put /playlists/{token}/video/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/video/{token}
Response samples Content type application/json
Delete video from playlist path Parameters token required
string
token reference for playlist or video
delete /playlists/{token}/video/{token}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/video/{token}
Add user with perms to playlist Request Body schema: application/x-www-form-urlencoded
username required
string
User to add/modify perms for the playlist
@@ -2246,42 +2256,42 @@
put /playlists/{token}/user
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/user
Get videos for the passed playlist query Parameters cid string
Course ID as context for the playlist
Responses 200 successful operation
-get /playlists/{token}/videos
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/videos
Response samples Content type application/json
Copy
Expand all Collapse all [ { "id" : 0 ,
"token" : "string" ,
"config_id" : 0 ,
"episode" : "string" ,
"title" : "string" ,
"description" : "string" ,
"duration" : 0 ,
"views" : 0 ,
"preview" :
{ "search" : "string" ,
"player" : "string" ,
"has_previews" : true
} , "visibility" : "string" ,
"created" : "2019-08-24T14:15:22Z" ,
"author" : "string" ,
"contributors" : "string" ,
"chdate" : 0 ,
"mkdate" : 0 ,
"paella" : "string" ,
"perm" : true ,
} ]
Get courses associated with the passed playlist path Parameters token required
get /playlists/{token}/videos
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/videos
Response samples Content type application/json
Copy
Expand all Collapse all [ { "id" : 0 ,
"token" : "string" ,
"config_id" : 0 ,
"episode" : "string" ,
"title" : "string" ,
"description" : "string" ,
"duration" : 0 ,
"views" : 0 ,
"preview" :
{ "search" : "string" ,
"player" : "string" ,
"has_previews" : true
} , "visibility" : "string" ,
"created" : "2019-08-24T14:15:22Z" ,
"author" : "string" ,
"contributors" : "string" ,
"chdate" : 0 ,
"mkdate" : 0 ,
"paella" : "string" ,
"perm" : true ,
} ]
Get courses associated with the passed playlist Responses 200 successful operation
-get /playlists/{token}/courses
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/courses
Response samples Content type application/json
Set course link Set course links for the playlist with the passed token, clearing out all not passed course links
+
get /playlists/{token}/courses
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/courses
Response samples Content type application/json
Set course link Set course links for the playlist with the passed token, clearing out all not passed course links
Request Body schema: application/json List of courses to link to
Responses 200 successful operation
-put /playlists/{token}/courses
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/courses
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Remove perms for user from playlist path Parameters token required
put /playlists/{token}/courses
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/courses
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Remove perms for user from playlist path Parameters token required
username required
delete /playlists/{token}/user/{username}
https://demo.studip.de/plugins.php/opencast/api /playlists/{token}/user/{username}
Set order of videos Set order of videos for the playlist with the passed token, giving each video a defined position
Request Body schema: application/json List of courses to link to
Responses 200 successful operation
-put /playlist/{token}/positions
https://demo.studip.de/plugins.php/opencast/api /playlist/{token}/positions
Request samples Content type application/json
[ "video_token_1" ,
"video_token_2"
]
Response samples Content type application/json
returns a list of all courses the current user has tutor perms for or higher Responses 200 successful operation
-get /courses
https://demo.studip.de/plugins.php/opencast/api /courses
Response samples Content type application/json
Copy
Expand all Collapse all Returns videos directly associated to this course path Parameters course_id required
put /playlist/{token}/positions
https://demo.studip.de/plugins.php/opencast/api /playlist/{token}/positions
Request samples Content type application/json
[ "video_token_1" ,
"video_token_2"
]
Response samples Content type application/json
returns a list of all courses the current user has tutor perms for or higher Responses 200 successful operation
+get /courses
https://demo.studip.de/plugins.php/opencast/api /courses
Response samples Content type application/json
Copy
Expand all Collapse all Returns videos directly associated to this course Responses 200 successful operation
-get /courses/{course_id}/videos
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/videos
Response samples Content type application/json
Copy
Expand all Collapse all [ { "id" : 0 ,
"token" : "string" ,
"config_id" : 0 ,
"episode" : "string" ,
"title" : "string" ,
"description" : "string" ,
"duration" : 0 ,
"views" : 0 ,
"preview" :
{ "search" : "string" ,
"player" : "string" ,
"has_previews" : true
} , "visibility" : "string" ,
"created" : "2019-08-24T14:15:22Z" ,
"author" : "string" ,
"contributors" : "string" ,
"chdate" : 0 ,
"mkdate" : 0 ,
"paella" : "string" ,
"perm" : true ,
} ]
Returns the config settings for this course, like series and configured workflow path Parameters course_id required
get /courses/{course_id}/videos
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/videos
Response samples Content type application/json
Copy
Expand all Collapse all [ { "id" : 0 ,
"token" : "string" ,
"config_id" : 0 ,
"episode" : "string" ,
"title" : "string" ,
"description" : "string" ,
"duration" : 0 ,
"views" : 0 ,
"preview" :
{ "search" : "string" ,
"player" : "string" ,
"has_previews" : true
} , "visibility" : "string" ,
"created" : "2019-08-24T14:15:22Z" ,
"author" : "string" ,
"contributors" : "string" ,
"chdate" : 0 ,
"mkdate" : 0 ,
"paella" : "string" ,
"perm" : true ,
} ]
Returns the config settings for this course, like series and configured workflow Responses 200 successful operation
-get /courses/{course_id}/config
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/config
Response samples Content type application/json
Copy
Expand all Collapse all { "series" :
{ "series_id" : "string" ,
"visibility" : "visible"
} , "workflow" : "upload"
}
Returns playlists for this course. Videos without explicit playlist in this course are mapped to a virtual playlist which can be accessed via the standard playlist routes path Parameters course_id required
get /courses/{course_id}/config
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/config
Response samples Content type application/json
Copy
Expand all Collapse all { "series" :
{ "series_id" : "string" ,
"visibility" : "visible"
} , "workflow" : "upload"
}
Returns playlists for this course. Videos without explicit playlist in this course are mapped to a virtual playlist which can be accessed via the standard playlist routes Responses 200 successful operation
-get /courses/{course_id}/playlists
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/playlists
Response samples Content type application/json
Add playlist to course path Parameters token required
get /courses/{course_id}/playlists
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/playlists
Response samples Content type application/json
Add playlist to course path Parameters token required
course_id required
Responses 200 successful operation
-put /courses/{course_id}/playlist/{token}
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/playlist/{token}
Response samples Content type application/json
Copy
Expand all Collapse all { "title" : "Meine Videos" ,
"description" : "string" ,
"visibility" : "internal" ,
"mkdate" : "2019-08-24T14:15:22Z" ,
"chdate" : "2019-08-24T14:15:22Z" ,
"references" :
[ { "course_id" : "string" ,
"visibility" : "hidden"
} ] }
Remove Playlist from course path Parameters token required
put /courses/{course_id}/playlist/{token}
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/playlist/{token}
Response samples Content type application/json
Copy
Expand all Collapse all { "title" : "Meine Videos" ,
"description" : "string" ,
"visibility" : "internal" ,
"mkdate" : "2019-08-24T14:15:22Z" ,
"chdate" : "2019-08-24T14:15:22Z" ,
"references" :
[ { "course_id" : "string" ,
"visibility" : "hidden"
} ] }
Remove Playlist from course path Parameters token required
course_id required
delete /courses/{course_id}/playlist/{token}
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/playlist/{token}
Get list of scheduled events for this course path Parameters course_id required
semester_filter required
string
ID of the selected semester filter or 'all'
Responses 200 successful operation
-get /courses/{course_id}/{semester_filter}/schedule
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/{semester_filter}/schedule
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Set visibility for course tab Sets, if the course tab is visible for non-privileged users in the passed course
+
get /courses/{course_id}/{semester_filter}/schedule
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/{semester_filter}/schedule
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Set visibility for course tab Sets, if the course tab is visible for non-privileged users in the passed course
path Parameters course_id required
visibility required
string
Enum: "free" "public" "internal"
Visibility for the course
get /courses/{course_id}/visibility/{visibility}
https://demo.studip.de/plugins.php/opencast/api /courses/{course_id}/visibility/{visibility}
Get opencast configuration with all servers Responses 200 successful operation
-get /config
https://demo.studip.de/plugins.php/opencast/api /config
Response samples Content type application/json
Copy
Expand all Collapse all [ { "settings" :
[ { "name" : "OPENCAST_SHOW_TOS" ,
"description" : "Müssen Lehrende einem Datenschutztext zustimmen, bevor sie das Opencast-Plugin in einer Veranstaltung verwenden können?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_ALTERNATE_SCHEDULE" ,
"description" : "Dürfen Lehrende abweichende Aufzeichnungszeiten einstellen?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_MEDIADOWNLOAD" ,
"description" : "Wird Nutzern angeboten, Aufzeichnungen herunterzuladen?" ,
"value" : true ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_STUDIO" ,
"description" : "Wird Nutzern angeboten, Aufzeichnungen mit Opencast Studio zu erstellen?" ,
"value" : true ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_HIDE_EPISODES" ,
"description" : "Sollen Videos standardmäßig nur für Lehrende sichtbar sein?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_TUTOR_EPISODE_PERM" ,
"description" : "Sollen Tutor/innen im Opencast-Plugin die gleichen Rechte haben wie Dozent/innen?" ,
"value" : true ,
"type" : "boolean"
} ] } ,
]
Update global configuration settings Request Body schema: application/x-www-form-urlencoded
settings required
string
User to add/modify perms for the playlist
+
get /tags
https://demo.studip.de/plugins.php/opencast/api /tags
Response samples Content type application/json
Get opencast configuration with all servers Responses 200 successful operation
+get /config
https://demo.studip.de/plugins.php/opencast/api /config
Response samples Content type application/json
Copy
Expand all Collapse all [ { "settings" :
[ { "name" : "OPENCAST_SHOW_TOS" ,
"description" : "Müssen Lehrende einem Datenschutztext zustimmen, bevor sie das Opencast-Plugin in einer Veranstaltung verwenden können?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_ALTERNATE_SCHEDULE" ,
"description" : "Dürfen Lehrende abweichende Aufzeichnungszeiten einstellen?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_MEDIADOWNLOAD" ,
"description" : "Wird Nutzern angeboten, Aufzeichnungen herunterzuladen?" ,
"value" : true ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_ALLOW_STUDIO" ,
"description" : "Wird Nutzern angeboten, Aufzeichnungen mit Opencast Studio zu erstellen?" ,
"value" : true ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_HIDE_EPISODES" ,
"description" : "Sollen Videos standardmäßig nur für Lehrende sichtbar sein?" ,
"value" : false ,
"type" : "boolean"
} ,
{ "name" : "OPENCAST_TUTOR_EPISODE_PERM" ,
"description" : "Sollen Tutor/innen im Opencast-Plugin die gleichen Rechte haben wie Dozent/innen?" ,
"value" : true ,
"type" : "boolean"
} ] } ,
]
Update global configuration settings Request Body schema: application/x-www-form-urlencoded
settings required
string
User to add/modify perms for the playlist
put /config
https://demo.studip.de/plugins.php/opencast/api /config
Get opencast configuration for server Responses 200 successful operation
@@ -2296,38 +2306,38 @@
get /lti/launch_data/{context_id}
https://demo.studip.de/plugins.php/opencast/api /lti/launch_data/{context_id}
Get scheduled event path Parameters course_id required
termin_id required
Responses 200 successful operation
-get /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Update a scheduled event path Parameters course_id required
get /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Update a scheduled event path Parameters course_id required
termin_id required
Request Body schema: */* Update an existing scheduled event
id resource_id required
date_id required
event_id
Responses 200 successful operation
-put /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Add a new scheduled event path Parameters course_id required
put /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
{ "id" : 0 ,
"resource_id" : "ddce269a1e3d054cae349621c198dd52" ,
"date_id" : "ddce269a1e3d054cae349621c198dd52" ,
"event_id" : "f8c3de3d-1fea-4d7c-a8b0-29f63c4c3454"
}
Add a new scheduled event path Parameters course_id required
termin_id required
Request Body schema: */* ScheduledEvent object to be added, course is determined by date_id
id resource_id required
date_id required
event_id
Responses 200 successful operation
-post /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
Delete a scheduled event path Parameters course_id required
post /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Response samples Content type application/json
Delete a scheduled event path Parameters course_id required
termin_id required
delete /schedule/{course_id}/{termin_id}
https://demo.studip.de/plugins.php/opencast/api /schedule/{course_id}/{termin_id}
Modify multiple scheduled events Pass a bulk operation type and a list of events to apply the bulk operation to
Request Body schema: application/json Schedule events to bulk operate on
action string
Enum: "schedule" "unschedule" "update" "live"
termin_ids
Responses 200 successful operation
-post /schedulebulk/{course_id}
https://demo.studip.de/plugins.php/opencast/api /schedulebulk/{course_id}
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Get user and roles by user name Returns the user with all necessary role ids
+
post /schedulebulk/{course_id}
https://demo.studip.de/plugins.php/opencast/api /schedulebulk/{course_id}
Request samples Content type application/json
Copy
Expand all Collapse all Response samples Content type application/json
Get user and roles by user name Returns the user with all necessary role ids
path Parameters username required
string
The name that needs to be fetched.
query Parameters token required
string
API Key to use for the call
Responses 400 Invalid username supplied
get /opencast/user/{username}
https://demo.studip.de/plugins.php/opencast/api /opencast/user/{username}
Response samples Content type application/json
Copy
Expand all Collapse all Get currently loggend in user Returns a data structur with details and permissions for the currently authenticated user
+
get /opencast/user/{username}
https://demo.studip.de/plugins.php/opencast/api /opencast/user/{username}
Response samples Content type application/json
Copy
Expand all Collapse all Get currently loggend in user Returns a data structur with details and permissions for the currently authenticated user
Responses 200 successful operation
-get /user
https://demo.studip.de/plugins.php/opencast/api /user
Response samples Content type application/json
Copy
Expand all Collapse all { "type" : "user" ,
"id" : "string" ,
"data" :
{ "id" : "string" ,
"username" : "string" ,
"fullname" : "string" ,
"status" : "user" ,
"admin" : true ,
"can_edit" : true
} }
Search for users Search in users accessible to the currently authenticated user
+
get /user
https://demo.studip.de/plugins.php/opencast/api /user
Response samples Content type application/json
Copy
Expand all Collapse all { "type" : "user" ,
"id" : "string" ,
"data" :
{ "id" : "string" ,
"username" : "string" ,
"fullname" : "string" ,
"status" : "user" ,
"admin" : true ,
"can_edit" : true
} }
Search for users Search in users accessible to the currently authenticated user
path Parameters search_term required
string
Part of user data to search for
Responses 200 successful operation
-get /user/search/{search_term}
https://demo.studip.de/plugins.php/opencast/api /user/search/{search_term}
Response samples Content type application/json
Copy
Expand all Collapse all [ { "type" : "user" ,
"id" : "string" ,
"data" :
{ "id" : "string" ,
"username" : "string" ,
"fullname" : "string" ,
"status" : "user" ,
"admin" : true ,
"can_edit" : true
} } ]
Log an event Pass details on log event type to create an entry in Stud.IPs log
+
get /user/search/{search_term}
https://demo.studip.de/plugins.php/opencast/api /user/search/{search_term}
Response samples Content type application/json
Copy
Expand all Collapse all [ { "type" : "user" ,
"id" : "string" ,
"data" :
{ "id" : "string" ,
"username" : "string" ,
"fullname" : "string" ,
"status" : "user" ,
"admin" : true ,
"can_edit" : true
} } ]
Log an event Pass details on log event type to create an entry in Stud.IPs log
Request Body schema: application/json Responses 204 successful operation
-post /log
https://demo.studip.de/plugins.php/opencast/api /log
Request samples Content type application/json
Response samples Content type application/json
+post /log
https://demo.studip.de/plugins.php/opencast/api /log
Request samples Content type application/json
Response samples Content type application/json
diff --git a/vueapp/components/Courses/CoursesSidebar.vue b/vueapp/components/Courses/CoursesSidebar.vue
index 56356de28..a5535d5a5 100644
--- a/vueapp/components/Courses/CoursesSidebar.vue
+++ b/vueapp/components/Courses/CoursesSidebar.vue
@@ -31,15 +31,7 @@
Wiedergabelisten
@@ -102,12 +102,17 @@
- {{ $gettext('Videos/Wiedergabeliste verknüpfen') }}
+ {{ $gettext('Videos/Wiedergabelisten übertragen') }}
+
+
@@ -115,14 +120,16 @@
import { mapGetters } from "vuex";
import StudipIcon from '@studip/StudipIcon.vue';
+import PlaylistAddCard from '@/components/Playlists/PlaylistAddCard.vue';
+
export default {
name: 'episodes-action-widget',
components: {
- StudipIcon
+ StudipIcon, PlaylistAddCard
},
- emits: ['uploadVideo', 'recordVideo'],
+ emits: ['uploadVideo', 'recordVideo', 'copyAll'],
data() {
return {
@@ -132,7 +139,7 @@ export default {
},
computed: {
- ...mapGetters(["playlists", "currentView",
+ ...mapGetters(["playlists", "currentView", 'addPlaylist',
"cid", "semester_list", "semester_filter", 'currentUser',
'simple_config_list', 'course_config', 'currentPlaylist']),
@@ -185,17 +192,10 @@ export default {
this.$store.commit('setCurrentPlaylist', token);
this.$store.commit('clearPaging');
- if (token === 'all' || token === null) {
- this.$store.dispatch('loadCourseVideos', {
- cid: this.cid,
- });
- } else {
- this.$store.dispatch('loadPlaylistCourseVideos', {
- cid: this.cid,
- token: token
- });
- }
-
+ this.$store.dispatch('loadPlaylistVideos', {
+ cid: this.cid,
+ token: token
+ });
},
getScheduleList() {
@@ -207,30 +207,64 @@ export default {
setView(page) {
this.$store.dispatch('updateView', page);
- if (this.currentPlaylist === 'all' || this.currentPlaylist === null) {
- this.$store.dispatch('loadCourseVideos', {
- cid: this.cid,
- });
- } else {
- this.$store.dispatch('loadPlaylistCourseVideos', {
- cid: this.cid,
- token: this.currentPlaylist
- });
- }
+ this.$store.dispatch('loadPlaylistVideos', {
+ cid: this.cid,
+ token: this.currentPlaylist
+ });
+
},
async setVisibility(visibility) {
await this.$store.dispatch('setVisibility', {'cid': this.cid, 'visibility': visibility});
this.$router.go(); // Reload page to make changes visible in navigation tab
+ },
+
+ showCreatePlaylist() {
+ this.$store.dispatch('addPlaylistUI', true);
+ },
+
+ cancelPlaylistAdd() {
+ this.$store.dispatch('addPlaylistUI', false);
+ },
+
+ createPlaylist(playlist) {
+ this.$store.dispatch('addPlaylist', playlist);
+ },
+
+ getDefaultPlaylist()
+ {
+ let currentPlaylist = null;
+
+ // set the courses default playlist
+ for (let id in this.playlists) {
+ if (this.playlists[id].is_default == '1') {
+ currentPlaylist = this.playlists[id].token;
+ }
+ }
+
+ // if no default is found, use the first playlist
+ if (this.currentPlaylist == null) {
+ for (let id in this.playlists) {
+ currentPlaylist = this.playlists[id].token;
+ break;
+ }
+ }
+
+ return currentPlaylist;
}
},
mounted() {
- this.$store.dispatch('loadPlaylists');
+ let view = this;
+ this.$store.dispatch('loadPlaylists').
+ then(() => {
+ view.$store.commit('setCurrentPlaylist', view.getDefaultPlaylist());
+ })
this.$store.dispatch('simpleConfigListRead');
this.$store.dispatch('loadCourseConfig', this.cid);
this.semesterFilter = this.semester_filter;
+
},
watch: {
@@ -244,6 +278,10 @@ export default {
currentPlaylist(newValue, oldValue) {
if (newValue !== oldValue) {
+ if (newValue === null) {
+ // use default playlist
+ newValue = this.getDefaultPlaylist();
+ }
this.setPlaylist(newValue);
}
}
diff --git a/vueapp/components/UserPlaylistSelectable.vue b/vueapp/components/UserPlaylistSelectable.vue
new file mode 100644
index 000000000..ada45b4bd
--- /dev/null
+++ b/vueapp/components/UserPlaylistSelectable.vue
@@ -0,0 +1,100 @@
+
+
+
+
+
diff --git a/vueapp/components/Videos/Actions/VideoAddToPlaylist.vue b/vueapp/components/Videos/Actions/VideoAddToPlaylist.vue
index e69de29bb..34a94e848 100644
--- a/vueapp/components/Videos/Actions/VideoAddToPlaylist.vue
+++ b/vueapp/components/Videos/Actions/VideoAddToPlaylist.vue
@@ -0,0 +1,106 @@
+
+
+
+
+
+
+
+
+ {{ $gettext('Wiedergabeliste') }}
+
+
+
+
+
+
+
+
+ {{ playlist.title }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/vueapp/components/Videos/Actions/VideoCopyToSeminar.vue b/vueapp/components/Videos/Actions/VideoCopyToSeminar.vue
index dfb31c84a..420551869 100644
--- a/vueapp/components/Videos/Actions/VideoCopyToSeminar.vue
+++ b/vueapp/components/Videos/Actions/VideoCopyToSeminar.vue
@@ -1,8 +1,8 @@
-
@@ -98,7 +73,7 @@ export default {
},
computed: {
- ...mapGetters(['userCourses', 'cid', 'courseVideosToCopy', 'courseCopyType']),
+ ...mapGetters(['userCourses', 'cid', 'courseVideosToCopy']),
user_courses_filtered() {
let userCoursesFiltered = this.userCourses;
@@ -135,7 +110,6 @@ export default {
let data = {
cid: this.cid,
courses: this.courses,
- type: this.courseCopyType,
tokens: this.courseVideosToCopy
};
await this.$store.dispatch('copyVideosToCourses', data)
@@ -151,12 +125,6 @@ export default {
});
},
- setCopyType(type) {
- if (['all', 'videos', 'playlists'].includes(type)) {
- this.$store.dispatch('setCourseCopyType', type);
- }
- },
-
decline() {
this.$emit('cancel');
}
diff --git a/vueapp/components/Videos/VideoCard.vue b/vueapp/components/Videos/VideoCard.vue
index 4b9849ef4..411f38851 100644
--- a/vueapp/components/Videos/VideoCard.vue
+++ b/vueapp/components/Videos/VideoCard.vue
@@ -184,9 +184,6 @@ export default {
if (this.canEdit) {
return true;
}
- if (this.currentPlaylist === 'all') {
- return this.downloadSetting === 'allow';
- }
let playlist_download = this.playlists.find(p => p['token'] === this.currentPlaylist)['allow_download'];
if (playlist_download === null) {
@@ -262,10 +259,10 @@ export default {
menuItems.push({
id: 2,
- label: this.$gettext('Verknüpfte Kurse'),
+ label: this.$gettext('Verknüpfungen'),
icon: 'add',
emit: 'performAction',
- emitArguments: 'VideoAddToSeminar'
+ emitArguments: 'VideoAddToPlaylist'
});
menuItems.push({
diff --git a/vueapp/components/Videos/VideosList.vue b/vueapp/components/Videos/VideosList.vue
index 0043ca1ab..88fb5edfe 100644
--- a/vueapp/components/Videos/VideosList.vue
+++ b/vueapp/components/Videos/VideosList.vue
@@ -12,12 +12,20 @@
-
- {{ $gettext('Wiedergabeliste aus diesem Kurs entfernen') }}
-
+
@@ -27,12 +35,14 @@
+
@@ -56,11 +66,11 @@
v-bind:key="event.token"
:playlistForVideos="playlistForVideos"
:selectedVideos="selectedVideos"
- :isCourse="isCourse"
@toggle="toggleVideo"
@doAction="doAction"
@redirectAction="redirectAction"
>
+
@@ -78,6 +88,8 @@
diff --git a/vueapp/router/index.js b/vueapp/router/index.js
index 513d15eba..3a6818126 100644
--- a/vueapp/router/index.js
+++ b/vueapp/router/index.js
@@ -7,7 +7,6 @@ export default new createRouter({
routes: [
{
path: "/contents",
- name: "contents",
component: () => import("@/views/Contents"),
children: [
{
@@ -21,7 +20,6 @@ export default new createRouter({
component: () => import("@/views/Playlists"),
},
-
{
path: 'playlists/:token/edit/',
name: 'playlist_edit',
diff --git a/vueapp/store/config.module.js b/vueapp/store/config.module.js
index 17d177b6c..9557583fd 100644
--- a/vueapp/store/config.module.js
+++ b/vueapp/store/config.module.js
@@ -36,7 +36,11 @@ const getters = {
},
downloadSetting(state) {
- return state.simple_config_list.settings['OPENCAST_MEDIADOWNLOAD'];
+ if (state.simple_config_list.settings !== undefined) {
+ return state.simple_config_list.settings['OPENCAST_MEDIADOWNLOAD'];
+ } else {
+ return false;
+ }
}
};
diff --git a/vueapp/store/opencast.module.js b/vueapp/store/opencast.module.js
index 8aa6a9f8e..7bdb33af1 100644
--- a/vueapp/store/opencast.module.js
+++ b/vueapp/store/opencast.module.js
@@ -9,7 +9,7 @@ const state = {
site: null,
axios_running: false,
userCourses: [],
- currentPlaylist: 'all',
+ currentPlaylist: null,
userList: []
}
diff --git a/vueapp/store/playlists.module.js b/vueapp/store/playlists.module.js
index c3dce928b..27b3a8f18 100644
--- a/vueapp/store/playlists.module.js
+++ b/vueapp/store/playlists.module.js
@@ -100,15 +100,22 @@ const actions = {
},
async addPlaylist({ commit, dispatch, rootState }, playlist) {
- // TODO
commit('setPlaylistAdd', false);
let $cid = rootState.opencast.cid;
- let $route = ($cid == null) ? 'playlists' : 'courses/' + $cid + '/playlists';
- return ApiService.post($route, playlist)
+ return ApiService.post('playlists', playlist)
.then(({ data }) => {
- dispatch('loadPlaylists');
+ if ($cid !== null) {
+ // connect playlist to new course
+ dispatch('addPlaylistToCourse', {
+ course: $cid,
+ token: data.token
+ })
+ .then(() => dispatch('loadPlaylists'))
+ } else {
+ dispatch('loadPlaylists');
+ }
});
},
diff --git a/vueapp/store/videos.module.js b/vueapp/store/videos.module.js
index ecedaee16..a5d511bad 100644
--- a/vueapp/store/videos.module.js
+++ b/vueapp/store/videos.module.js
@@ -20,7 +20,6 @@ const state = {
videoShares: {},
courseVideosToCopy: [],
showCourseCopyDialog: false,
- courseCopyType: 'all',
}
const getters = {
@@ -63,10 +62,6 @@ const getters = {
showCourseCopyDialog(state) {
return state.showCourseCopyDialog
},
-
- courseCopyType(state) {
- return state.courseCopyType
- }
}
const actions = {
@@ -125,23 +120,6 @@ const actions = {
})
},
- async loadCourseVideos({ commit, state, dispatch, rootState }, data)
- {
- let cid = data?.cid ?? window?.OpencastPlugin?.CID;
- return dispatch('loadVideos', {
- route: 'courses/' + cid + '/videos',
- filters: data,
- })
- },
-
- async loadPlaylistCourseVideos({ commit, state, dispatch, rootState }, data)
- {
- return dispatch('loadVideos', {
- route: 'playlists/' + data.token + '/videos/?cid=' + data.cid,
- filters: data,
- })
- },
-
async uploadSortPositions({}, data) {
return ApiService.put('playlists/' + data.playlist_token + '/positions', data.sortedVideos)
},
@@ -158,8 +136,8 @@ const actions = {
return ApiService.post('videos/' + data.token + '/report', {description: data.description});
},
- async addVideoToCourses(context, data) {
- return ApiService.post('videos/' + data.token + '/courses', {courses: data.courses});
+ async addVideoToPlaylists(context, data) {
+ return ApiService.post('videos/' + data.token + '/playlists', {playlists: data.playlists});
},
async copyVideosToCourses(context, data) {
@@ -207,10 +185,6 @@ const actions = {
toggleCourseCopyDialog({dispatch, state, commit}, mode) {
commit('setShowCourseCopyDialog', mode);
- },
-
- setCourseCopyType({dispatch, state, commit}, type) {
- commit('setCourseCopyType', type);
}
}
@@ -266,11 +240,7 @@ const mutations = {
setShowCourseCopyDialog(state, mode) {
state.showCourseCopyDialog = mode;
- },
-
- setCourseCopyType(state, type) {
- state.courseCopyType = type;
- },
+ }
}
export default {
diff --git a/vueapp/views/Course.vue b/vueapp/views/Course.vue
index 772069393..2a8534456 100644
--- a/vueapp/views/Course.vue
+++ b/vueapp/views/Course.vue
@@ -64,7 +64,6 @@ export default {
copyAll() {
this.$store.dispatch('toggleCourseCopyDialog', true);
- this.$store.dispatch('setCourseCopyType', 'all');
},
closeCopyDialog() {
@@ -77,7 +76,6 @@ export default {
resetCopyParams() {
this.$store.dispatch('toggleCourseCopyDialog', false);
- this.$store.dispatch('setCourseCopyType', 'all');
this.$store.dispatch('setCourseVideosToCopy', []);
}
},