1234567891011121314151617181920212223242526272829 |
- <?php
- require dirname(__FILE__) . '/../vendor/autoload.php';
- $secretId = "SECRETID";
- $secretKey = "SECRETKEY";
- $region = "ap-beijing";
- $cosClient = new Qcloud\Cos\Client(
- array(
- 'region' => $region,
- 'schema' => 'https',
- 'credentials'=> array(
- 'secretId' => $secretId ,
- 'secretKey' => $secretKey)));
- try {
- $result = $cosClient->GetMediaInfo(
- array(
- 'Bucket' => 'examplebucket-125000000',
- 'Key' =>'exampleobject',
- 'ci-process' => 'videoinfo'
- )
- );
-
- echo($result);
- } catch (\Exception $e) {
-
- echo($e);
- }
|