share_list

Get a list of all shared objects for a user.

Explorer

Explore this method

Request URL

http://api.tubemogul.com/api/v3/

HTTP method

POST

Arguments

type (integer) - Optional
Optional The type of the object shared. This value can be tracker or publisher.
id (integer) - Optional
Optional The id of the object that is shared.
site_id (integer) - Optional
Optional The site id of the video site to which the publisher specified in the id field belongs.

Returned Status Codes

0 : Unknown Error.
1 : Successful

Example Response

<?xml version="1.0" encoding="utf-8" ?>
<response stat="ok">
    <shared_objects_list count="2">
          <shared_object>
             <share_type>
                user
             </share_type>
             <object_type>
                tracker
             </object_type>
             <object_id>
                TR-AGK-QEA
             </object_id>
             <email>
                kshama_thacker@yahoo.co.in
             </email>
             <display_name_share>
                kshama_thacker@yahoo.co.in
             </display_name_share>
          </shared_object>
          <shared_object>
             <share_type>
                user
             </share_type>
             <object_type>
                tracker
             </object_type>
             <object_id>
                1234
             </object_id>
             <email>
                kshama_thacker@yahoo.co.in
             </email>
             <display_name_share>
                kshama_thacker@yahoo.co.in
             </display_name_share>
          </shared_object>
       </shared_objects_list>
</response>

Error Codes

Standard error codes plus:

20 : the identifier requested does not belong to the specified user or the user does not have inplay permission

Example Code

<?
# Your user token
$user_token '';

# Your partner ID
$partner_id '';

# Your secret key
$secret_key '';

# type of share (publisher / tracker)
$type '';

# id of the shared object
$id '';

# TubeMogul site id of the publisher shared
$site_id '';

$method 'share_list';

$now time();

$apihost 'http://api-upload.tubemogul.com/index.php';

$poststring "date=".$now.
              
"&userToken=".urlencode($user_token).
              
"&partnerID=".urlencode($partner_id).
              
"&type=".urlencode($type).
              
"&id=".urlencode($id).
              
"&site_id=".urlencode($site_id).
              
"&method=".$method;

$hash sha1($secret_key.$poststring);

$poststring .= "&hash=".$hash;

echo 
$poststring;
?>

<br /><br />
<form action='<? echo $apihost?>' method='post'>
<input type='hidden' name='date' value='<? echo $now?>' />
<input type='hidden' name='userToken' value='<? echo $user_token?>' />
<input type='hidden' name='partnerID' value='<? echo $partner_id?>' />
<input type='hidden' name='type' value='<? echo $type?>' />
<input type='hidden' name='id' value='<? echo $id?>' />
<input type='hidden' name='site_id' value='<? echo $site_id?>' />
<input type='hidden' name='method' value='<? echo $method?>' />
<input type='hidden' name='hash' value='<? echo $hash?>' />
<input type='submit' value='submit!' />
</form>