{"base_path":"/","components":null,"consumes":"[\"application/json;charset=UTF-8\"]","definitions":{"UpdateResponse":{"properties":{"result":{"description":"处理成功时返回","example":"success","type":"string"}}},"UpdateRetentionRequestList":{"properties":{"bucket":{"description":"OBS桶名,当“store_type”为“obs”时必选。","example":"obs-momo","type":"string"},"format":{"default":"FLV","description":"视频流转储格式。\n- H264支持MP4和FLV\n- H265只支持MP4\n\n默认为FLV。","enum":["MP4","FLV"],"example":"FLV","type":"string"},"path":{"description":"OBS目录,当“store_type”为“obs”时,该参数必选。该目录下的文件夹最多为N+2个,N为转储时长。","example":"path/to/video/","type":"string"},"slice_in_minute":{"description":"分片长度,以分钟为单位。取值范围为1~60,默认为5。","example":"1","maximum":60,"minimum":1,"type":"integer"},"state":{"description":"转储状态。\n- ACTIVE:表示进行转储。\n- STOPPED:表示停止转储。\n\n默认为STOPPED。","enum":["ACTIVE","STOPPED"],"example":"ACTIVE","type":"string"},"store_type":{"description":"视频转储位置,可为“obs”,即存储到云服务OBS上。第一次创建转储信息时必选,不区分大小写。","enum":["OBS"],"example":"obs","type":"string"},"timezone":{"description":"当地时区。格式为GMT+HH:00,如GMT+8:00表示东八区。转储时路径命名以该时区时间为准。","example":"GMT+8:00","pattern":"GMT(\\+|-)([0]?)([0-9]|1[0-2]):00","type":"string"}},"required":["timezone"]}},"description":null,"group_id":"5346b7c1dc284228a28795d5bcbd550d","host":"vis.cn-north-4.myhuaweicloud.com","id":"101eacc1912d4b02956d8e0e47423910","info_version":"v1","method":"put","name":"UpdateRetention","parameters":{"Authorization":{"description":"使用AK/SK方式认证时必选,携带的鉴权信息。","in":"header","maxLength":256,"minLength":1,"name":"Authorization","required":false,"type":"string","x-example":"SDK-HMAC-SHA256 Access=xxx, SignedHeaders=content-type;host;x-sdk-date, Signature=xxx"},"X-Auth-Token":{"description":"普通租户的token。","in":"header","maxLength":10240,"minLength":1,"name":"X-Auth-Token","required":true,"type":"string"},"X-Project-Id":{"description":"使用AK/SK方式认证时必选,携带项目ID信息。","in":"header","maxLength":64,"minLength":1,"name":"X-Project-Id","required":false,"type":"string","x-example":"70b76xxxxxx34253880af501cdxxxxxx"},"X-Sdk-Date":{"description":"使用AK/SK方式认证时必选,请求的发生时间。","in":"header","maxLength":256,"minLength":1,"name":"X-Sdk-Date","required":false,"type":"string","x-example":"20191115T033655Z"},"project_id":{"description":"项目ID,获取方法请参考[获取项目ID](https://support.huaweicloud.com/api-vis/vis_03_0005.html)","in":"path","maxLength":32,"minLength":32,"name":"project_id","required":true,"type":"string"}},"paths":{"/v1/{project_id}/streams/{stream_name}/retention":{"put":{"consumes":[],"deprecated":false,"description":"此接口用于更新视频转储信息。创建的视频流默认没有转储信息,即视频数据不会保存。更新转储信息后可以将视频流保存到指定的存储媒介,如OBS。后续用户可以从OBS上获取到转储的视频。\n\n- 如果转储到OBS,在调用该API之前,需要您先授予VIS操作OBS的权限,授权操作只需要操作一次即可,后续转储无需再操作。授权方法如下:\n\n 1. 登录视频接入服务控制台。\n\n 2. 在\"视频流管理\"页面,找到您需要转储的已激活视频流,单击操作列的\"开始转储\"。\n\n 3. 如果您之前没有OBS授权,则系统会提示您进行OBS授权,单击\"同意授权\"即可。\n\n- 如果转储到OBS,最终生成的视频文件路径为\n\"/OBS路径/视频流名称/year/month/day/hour/startmin.sec_endmin.sec.flv,例如obs:path/to/video/streamName/2018/8/18/18/0000_0200.flv。\"","operationId":"UpdateRetention","parameters":[{"$ref":"#/parameters/project_id"},{"$ref":"#/parameters/X-Auth-Token"},{"$ref":"#/parameters/Authorization"},{"$ref":"#/parameters/X-Sdk-Date"},{"$ref":"#/parameters/X-Project-Id"},{"description":"视频流名称","in":"path","name":"stream_name","required":true,"type":"string","x-example":"strea***"},{"description":"创建视频流请求体\"","in":"body","name":"UpdateRetentionRequest","required":false,"schema":{"$ref":"#/definitions/UpdateRetentionRequestList"}}],"produces":[],"responses":{"200":{"description":"正常","examples":{"application/json":{"result":"success"}},"schema":{"$ref":"#/definitions/UpdateResponse"}},"400":{"description":"请求错误","examples":{"application/json":{"error_code":"VIS.0202","error_msg":"The entered stream ID does not exist."}}}},"summary":"更新转储信息","tags":["视频流管理"],"x-apiexplorer-hide":"N","x-is-registered":"Y","x-name":"更新转储信息","x-request-examples-1":{"bucket":"obs-momo","path":"path/**/video/***","slice_in_minute":1,"state":"ACTIVE","store_type":"obs","timezone":"GMT+8:00"},"x-request-examples-url-1":"PUT /v1/3266392d188c47d09948b1**********/streams/streamTest/retention","x-support-sdk":"Y"}}},"product_short":"VIS","region_id":"cn-north-4","schemes":["HTTPS"],"security_definitions":null,"summary":"更新转储信息","tags":"视频流管理","uri":null,"version":"2.0"}