Request to API partner/get endpoint results in error SERVICE_FORBIDDEN

partnerget
#1

Hi. I have installed Kaltura CE 14.16 on CentOS 6 server and trying to use API to get the partner’s details using -2 admin console account.

I am creating an application using Laravel that would allow to control the data inside Kaltura. I am the beginning of this process and trying to read the partner’s details from API using the /service/partner/action/get endpoint with partner ID -2 - admin console. But I am receiving an error - SERVICE_FORBIDDEN

I have tried to go through the permission checking login on the API side. But it seems to be correct there.

Do I have to enable something in the permissions for this call to work?

REQUEST:
POST http://kaltura.local:280/api_v3/service/partner/action/get HTTP/1.1

{“format”:“2”,“ignoreNull”:true,“clientTag”:“php5:19-04-04”,“apiVersion”:“14.16.0”,“id”:“104”,“ks”:“OWQ3NjE4MTUxNGU0Nzc0ZjE0MTNlMzQ0N2YxMThiZjI3YTc1ZjM1ZHwtMjstMjsxNTU1NzUxODc0OzI7Mjc5OTg7Ow==”,“partnerId”:“104”,“kalsig”:“1bf2f0dcb9c68d0a520be5b98d4bcaf4”}

RESPONSE:
HTTP/1.1 200 OK
Server: Apache/2.2.15 (CentOS)
X-Powered-By: PHP/5.3.3
X-Kaltura-Session: 1456854329
X-Kaltura: error-SERVICE_FORBIDDEN
X-Kaltura-App: exiting on error SERVICE_FORBIDDEN - The access to service [partner->get] is forbidden

<?xml version="1.0" encoding="utf-8"?><xml><result><error><code>SERVICE_FORBIDDEN</code><message>The access to service [partner-&gt;get] is forbidden</message><objectType>KalturaAPIException</objectType><args><item><objectType>KalturaApiExceptionArg</objectType><name>SERVICE</name><value>partner-&gt;get</value></item></args></error></result><executionTime>0.42037892341614</executionTime></xml>

0 Likes

#2

Hi @alexey_plodenko,

What exactly are you trying to accomplish? If you’re trying to imitate the Admin Console functionality and get a list of all the partners then you need to use the Admin Console client [see /opt/kaltura/app/admin_console/lib/Kaltura/Client/SystemPartner/].

If you just want to obtain your own partner object, then you should call partner.get() with a KS that belongs to that partner [104 in your example], not the -2 [the Admin Console system partner] KS.

0 Likes