12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- <?php
- require dirname(__FILE__, 2) . '/vendor/autoload.php';
- $secretId = "SECRETID";
- $secretKey = "SECRETKEY";
- $region = "ap-beijing";
- $cosClient = new Qcloud\Cos\Client(
- array(
- 'region' => $region,
- 'scheme' => 'https',
- 'credentials'=> array(
- 'secretId' => $secretId ,
- 'secretKey' => $secretKey)));
- try {
-
- $result = $cosClient->PostWatermarkJobs(array(
- 'Bucket' => '###bucketName###',
- 'Headers' => array(
- 'Content-Type' => 'application/xml',
- ),
- 'Tag'=> 'undefined',
-
- 'Input'=> array(
- 'Object'=> 'undefined',
- ),
-
- 'Operation'=> array(
- 'WatermarkTemplateId'=> 'undefined',
- 'UserData'=> 'undefined',
- 'JobLevel'=> 'undefined',
- ),
- 'CallBackFormat'=> 'undefined',
- 'CallBackType'=> 'undefined',
- 'CallBack'=> 'undefined',
- ));
-
- print_r($result);
- } catch (\Exception $e) {
-
- echo($e);
- }
|