How to list all categories that have some Privacy Context?

Hello,
I’m trying to list all categories using test API console. But in the list’s result I can’t see categories with entitlements settings (it means that some Privacy Context is assigned to the category).
For example in the KMC - Settings - Integration Settings - Entitlement Settings, setting some category as Root Category automatically assigns a Privacy Context to it. But this root category is not in the category.list response.

So, my question is how to pass Private Context name within request (category.list) or during session creation? Or how to list all categories for partnerId despite Privacy Context?

My main goal is to manage entitlement settings of channels/categories and users permissions using Kaltura API (Java client).

Hello,

You can simply create a session passing along ‘disableentitlement’:
String privileges = “disableentitlement”;
Object result = client.getSessionService().start(secret, userId, type, partnerId, expiry, privileges);

This is also what KMC does.

2 Likes

Thank you!
Where can I get a list with all possible privileges?

Welcome:) and here you go:

1 Like

Perfect,
Thank you again!

Hi @jess I’m having a similar issue, even if I set privileges = “disableentitlement” when generating the KS with ad admin token.

I have a video published inside a category with privacy context. This call

curl --request POST
–url https://www.kaltura.com/api_v3/service/media/action/get
–header ‘Content-Type: application/x-www-form-urlencoded’
–data ks=XXXXXXXXXXXXXXX
–data format=1
–data entryId=XXXXXX

gives me all the entry informations, except the category where it is published. If I change entryId and I choose one in a category without privacy context that attribute is showed. What should I change in may workflow in order to see that values?

Hello @scollovati,

Please use the categoryEntry.list() API with the KalturaCategoryEntryFilter::entryIdEqual filter member.
See https://developer.kaltura.com/console/service/categoryEntry/action/list

Cheers,

Thank you @jess, but why cannot we use the media.get service?
In this case, we’ll have to double the number of api calls for obtaining the same result.