PHP code example of xmeltrut / ooyala-php-v2-sdk

1. Go to this page and download the library: Download xmeltrut/ooyala-php-v2-sdk library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

xmeltrut / ooyala-php-v2-sdk example snippets



    $api = new OoyalaApi("<api key>", "<secret key>");


    $parameters = array("where" => "labels INCLUDES 'Funny dogs'");

    $results = $api->get("assets", $parameters);
    $assets = $results->items;


    echo "Printing assets in the 'Funny dogs' label...";
    foreach($assets as $asset) {
        echo $asset->embed_code . " - " . $asset->name . "\n";
    }