How to create/access MediaSpace channel playlist with API


Hello All,
I am trying to create MediaSpace channel playlists and set its entitlements with Kaltura API. I manually created new Mediaspace channel and playlist under it. I can see it automatically created new category with the channel name and new playlist in KMC and they are connected with unknown property channelPlaylistsIds inside the category metadata. I believe I can now set entitlements on this category and it controls access to channel playlist and its media. My question is which API to use to create such channel and channel playlist? I was out of luck searching API docs.
Thanks for any ideas,

Private videos in media list response

Hi @z.dusatko,

In regards to KMS channels, please see my explanation here:

As for creating playlists, the APIs for that are here:

In MediaSpace, you can also configure which playlist will be used for the carousel module but that requires access to the KMS admin console.
Playlists can be static (containing a fixed list of entries) or dynamic (baseed on a rules).


Hi Jess,
thanks for a quick response. I am assuming I can search for metadata for particular category id and particular metadataProfileId with metadata.list but I am confused how to get metadataProfileId for metadata property “channelPlaylistsIds”. I see metadataProfile.list but I am not sure which filter to use.


Hi @z.dusatko,

Not sure I understand your end goal. Can you please explain what it is you’re trying to achieve?
If you want to filter playlists according to categories, you can use:

$filter = new KalturaPlaylistFilter();
$result = $client->playlist->listAction($filter, $pager);

Where the following category related filters are available:


As you can see, you can filter by category IDs or by category names. For the logical AND and OR operations, a comma separated list can be passed, as in:
"$catId0, $catId1"
$catName0, $catName1"

The above is PHP code but of course, this is available for any of the Kaltura API clients.
You can look at:

Which exposes all filtering options and will also generate code in the selected language.


Hi Jess,
my end goal is to create Mediaspace channel playlist with API. If I understand it correctly I need to create category and playlist. To glue it together I need to create metadata for this category with field named “channelPlaylistsIds”. Now to create metadata I need metadataProfile, my question is how do I find this metadataProfile knowing only its field name “channelPlaylistsIds”? Not sure if I just made it more confusing. Thanks for your patience.


Hi @z.dusatko,

Below are the requests needed to create a new playlist and attach it to a given channel. I’ve annotated each request, explaining the parameters. Note of course that the IDs will be different in your case and that you should call the list() action for the relevant service with the correct filter to obtain the right IDs.

The requests are in pure HTTP form since I don’t know which API client you using, you should call the corresponding service and action pair from your code.

You can generate the code samples for making each such request for your client by going to and typing the SERVICE.ACTION in the search box and then clicking on “Try it out”.

# create a playlist called "myplay":

# get a list of sub categories under MediaSpace>playlists:

# add a new category entry record/object with entryId=0_wbm71z1c, 0_wbm71z1c is the playlist ID returned from the 
service=playlist&action=add request, categoryId=50 is MediaSpace>playlists on my ENV: 

# update the relevant metadata object:
# metadata ID 5 has:
# metadata_profile_id: 12 - that's the ID for the profile whose name is CategoryAdditionalInfo on my ENV]
# objectIdIn: 140 - the category ID for MediaSpace>site>channels>mbp which is the channel I want this playlist to be attached to
# <Value>0_wbm71z1c,0_jlpl1snw,0_9fxaraxx,</Value> - since this channel already has 2 priorly created playlists, we need to concat the new one, 0_wbm71z1c to those who already exist, hence the metadata->list request from before]

/api_v3/index.php?service=metadata_metadata&action=update&id=5&xmlData=<?xml version="1.0"?>

Hope this helps,

Creating playlists for courses within KAF using API