easyswoole阿里云获取视频信息(继承上面 easyswoole上传视频到阿里云)

  • App/HttpController/Index.php
public function getVideoInfo(){
        $videoId='0fda2220f2504ba9b549307039166145';
        $obj=new AliVod();
        $result=$obj->getPlayInfo($videoId);
        print_r($result);
    }
  • App/Lib/AliyunSdk/AliVod.php
public function getPlayInfo($videoId=0){
    if(empty($videoId)){
        return [];
    }
    $request=new vod\GetPlayInfoRequest();
    $request->setVideoId($videoId);
    $request->setAcceptFormat('JSON');
    return $this->client->getAcsResponse($request);
}
上一篇:AlibabaCloud 核⼼组件服务治理 Nacos 实战


下一篇:ssm使用全注解实现增删改查案例——IEmpMapper