Setting adminTags fails

10 replies [Last post]
Joined: 05/20/2009
Points: 6

Hi there,

I'm trying to create a roughcut entry and the following code works fine except that my admin tags are not set ?!?

$K_entry = new KalturaEntry();
$K_entry->name = $this->data['Utils']['title'];
$K_entry->tags = "COMMON_TAGS";
$K_entry->adminTags = "WIZ_TEMPLATE";

$res = $KalBasic->addRoughcutEntry( $K_entry );

Any idea why ?

Thanks

Joined: 01/05/2009
Points: 1697

To set an adminTag you should be using an admin KS.
To create an admin KS pass the admin secret when calling start/startsession.

If you did use admin KS, can you post the full code here ?

Joined: 02/22/2009
Points: 38

wow you have no idea how long I've been wrestling with this. so obvious and yet..

Joined: 05/14/2009
Points: 69

When I use admin KS, addRoughcutEntry will not work. Doesn't matter if adminTags has value or not.
I even tested addRoughcutEntry with admin KS on Test Console. It doesn't work on Test Console, either. Any Idea?
Thanks

Joined: 01/05/2009
Points: 1697

in api_v2 (aka ps2/ partner services 2) for security reasons, the admin KS and regular KS have a different meaning and usage - some of the apis will not work when using an admin KS and some require only an admin KS.

Using the public testMe console, the colors of the fields indicate what type of KS you should use -
No color - no KS is required.
Blue - startsession/ startwidgetsession
Orange - admin KS
Green - regular KS

in api_v3 (aka ps3/ partner services 3) admin KS is superior and can be used to access all apis.

There is a way to create an admin KS that will behave the same as in api_v3 (i.e. access all apis), and that's by passing 2 in the 'admin' field when creating the session using startsession api with your admin KS.

Using an admin KS publicly (e.g. on the site visible to the user, passing it to the editor) is not advised, as it makes your implementation vulnerable, so use the admin KS with care.

Joined: 04/05/2009
Points: 354

I have just noticed that you can only modify the admin tag using the API if you pass "2" in the admin field when creating the KS. If you just pass "1" you will get a Invalid KS error message. Strange!

Joined: 04/05/2009
Points: 11

I test the api v3 in updating the a playlist admintag....But I fail..please check this out..
thanx guys..

Joined: 04/05/2009
Points: 354

Could you please provide some more information?

Joined: 04/05/2009
Points: 11

please check this image I attached..I always failed to update the playlist admintag eventhough my session is admin.

AttachmentSize
snapshot.gif26.54 KB
Joined: 04/05/2009
Points: 354

I'm presuming the session was started using the admin secret?

Joined: 04/05/2009
Points: 11

Yes, I used the admin secret. still I cant changed the playlist admintag only tag.