Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 

Elastic Transcoder PHP Class

PHP class for interacting with Amazon Elastic Transcoder that does not require PEAR.

Usage

Object-oriented method:

$et = new AWS_ET($awsAccessKey, $awsSecretKey, $awsRegion);

Statically:

AWS_ET::setAuth($awsAccessKey, $awsSecretKey, $awsRegion);

Note: us-east-1 is the default AWS region setting. The third parameter is optional for us-east-1 users.

Job Operations

Creating a transcoding job:

$pipelineId = 'pipelineId';
$input = array('Key' => 'inputFile');
$output = array(
  'Key' => 'outputFile.mp4',
  'PresetId' => 'presetId'
 );

$result = AWS_ET::createJob($input, array($output), $pipelineId);

if (!$result) {
  echo AWS_ET::getErrorMsg();
} else {
  echo 'New job ID: ' . $result['Job']['Id'];
}

List jobs by pipeline:

AWS_ET::listJobsByPipeline( string $pipelineId [, boolean $ascending = true ] );

List jobs by status:

AWS_ET::listJobsByStatus( string $status );

Get job info:

AWS_ET::readJob( string $jobId );

Cancel a job:

AWS_ET::cancelJob( string $jobId );

Pipeline Operations

Create a new pipeline:

AWS_ET::createPipeline( string $name, string $inputBucket, string $outputBucket, string $role [, array $notifications ] );

Get a list pipelines:

AWS_ET::listPipelines();

Get info about a pipeline:

AWS_ET::readPipeline( string $pipelineId );

Update pipeline settings:

AWS_ET::updatePipeline( string $pipelineId, array $updates );

Change the status of a pipeline (active/paused):

AWS_ET::updatePipelineStatus( string $pipelineId, string $status );

Update pipeline notification settings:

AWS_ET::updatePipelineNotifications( string $pipelineId [, array $notifications ] );

Delete a pipeline:

AWS_ET::deletePipeline( string $pipelineId );

Test the settings for a pipeline:

AWS_ET::testRole( string $inputBucket, string $outputBucket, string $role, array $topics );

Preset Operations

Create a preset:

AWS_ET::createPreset( array $options );

List all presets:

AWS_ET::listPresets();

Get info about a preset:

AWS_ET::readPreset( string $presetId );

Delete a preset:

AWS_ET::deletePreset( string $presetId );

Misc.

Set AWS authentication credentials:

AWS_ET::setAuth( string $awsAccessKey, string $awsSecretKey );

Set AWS region:

AWS_ET::setRegion( string $region = 'us-east-1' );

Get HTTP status code of server response:

AWS_ET::getStatusCode();

Get server response:

AWS_ET::getResponse();

Get error message, if any:

AWS_ET::getErrorMsg();

More Information:
Getting Started with Elastic Transcoder

License

Released under the MIT license.

githalytics.com alpha

About

Standalone Amazon Elastic Transcoder client for PHP 5.2+

Resources

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages