Media Objects
Closed captions added to a video MediaObject
When you upload or record webcam video/audio to kaltura, it makes a Media Object
A MediaTrack object looks like:
A MediaObject object looks like:
GET /api/v1/media_objects/:media_object_id/media_tracks
GET /api/v1/media_objects/:media_object_id/media_tracks
Scope: url:GET|/api/v1/media_objects/:media_object_id/media_tracks
GET /api/v1/media_attachments/:attachment_id/media_tracks
GET /api/v1/media_attachments/:attachment_id/media_tracks
Scope: url:GET|/api/v1/media_attachments/:attachment_id/media_tracks
List the media tracks associated with a media object or attachment
Request Parameters:
Parameter | Type | Description |
---|---|---|
|
| By default, index returns id, locale, kind, media_object_id, and user_id for each of the result MediaTracks. Use include[] to add additional fields. For example include[]=content Allowed values: |
Example Request:
Returns a list of MediaTrack objects.
PUT /api/v1/media_objects/:media_object_id/media_tracks
PUT /api/v1/media_objects/:media_object_id/media_tracks
Scope: url:PUT|/api/v1/media_objects/:media_object_id/media_tracks
PUT /api/v1/media_attachments/:attachment_id/media_tracks
PUT /api/v1/media_attachments/:attachment_id/media_tracks
Scope: url:PUT|/api/v1/media_attachments/:attachment_id/media_tracks
Replace the media tracks associated with a media object or attachment with the array of tracks provided in the body. Update will delete any existing tracks not listed, leave untouched any tracks with no content field, and update or create tracks with a content field.
Request Parameters:
Parameter | Type | Description |
---|---|---|
|
| By default, an update returns id, locale, kind, media_object_id, and user_id for each of the result MediaTracks. Use include[] to add additional fields. For example include[]=content Allowed values: |
Example Request:
Returns a list of MediaTrack objects.
GET /api/v1/media_objects
GET /api/v1/media_objects
Scope: url:GET|/api/v1/media_objects
GET /api/v1/courses/:course_id/media_objects
GET /api/v1/courses/:course_id/media_objects
Scope: url:GET|/api/v1/courses/:course_id/media_objects
GET /api/v1/groups/:group_id/media_objects
GET /api/v1/groups/:group_id/media_objects
Scope: url:GET|/api/v1/groups/:group_id/media_objects
GET /api/v1/media_attachments
GET /api/v1/media_attachments
Scope: url:GET|/api/v1/media_attachments
GET /api/v1/courses/:course_id/media_attachments
GET /api/v1/courses/:course_id/media_attachments
Scope: url:GET|/api/v1/courses/:course_id/media_attachments
GET /api/v1/groups/:group_id/media_attachments
GET /api/v1/groups/:group_id/media_attachments
Scope: url:GET|/api/v1/groups/:group_id/media_attachments
Returns media objects created by the user making the request. When using the second version, returns media objects associated with the given course.
Request Parameters:
Parameter | Type | Description |
---|---|---|
|
| Field to sort on. Default is “title”
Allowed values: |
|
| Sort direction. Default is “asc” Allowed values: |
|
| Array of data to exclude. By excluding “sources” and “tracks”, the api will not need to query kaltura, which greatly speeds up its response.
Allowed values: |
Example Request:
Returns a list of MediaObject objects.
MediaObjectsController#update_media_object
PUT /api/v1/media_objects/:media_object_id
PUT /api/v1/media_objects/:media_object_id
Scope: url:PUT|/api/v1/media_objects/:media_object_id
PUT /api/v1/media_attachments/:attachment_id
PUT /api/v1/media_attachments/:attachment_id
Scope: url:PUT|/api/v1/media_attachments/:attachment_id
© Instructure, Inc. Generated on Wed Nov 6 14:20:07 2024 This documentation is generated directly from the Canvas LMS source code, available on Github.
Last updated