DemoUpload.php 403 B

1234567891011121314151617
  1. <?php
  2. require('../../vendor/autoload.php');
  3. use Volc\Service\ImageX;
  4. $client = ImageX::getInstance();
  5. // call below method if you dont set ak and sk in ~/.volc/config
  6. $client->setAccessKey("ak");
  7. $client->setSecretKey("sk");
  8. $params = array();
  9. $params["ServiceId"] = "imagex service id";
  10. $filePaths = array("image path 1");
  11. $response = $client->uploadImages($params, $filePaths);
  12. echo $response;