summaryrefslogtreecommitdiff
path: root/data/en_us/videoseg/2020-03-20/api-docs.php
diff options
context:
space:
mode:
authorZhineng Li <im@zhineng.li>2026-07-12 17:11:17 +0800
committerZhineng Li <im@zhineng.li>2026-07-12 17:11:17 +0800
commit1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634 (patch)
tree5f0857666365b7e40cdaa3733ebe1f3ba9e13c67 /data/en_us/videoseg/2020-03-20/api-docs.php
parent7347bac4ab7e136157fc94777e6cf87ef9e08599 (diff)
downloadafterglow-metadata-full-1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634.tar.gz
afterglow-metadata-full-1c7f908ce09f98fdcbf79ed2a8ae21be60eaa634.zip
update APIs 20260712
Diffstat (limited to 'data/en_us/videoseg/2020-03-20/api-docs.php')
-rw-r--r--data/en_us/videoseg/2020-03-20/api-docs.php446
1 files changed, 307 insertions, 139 deletions
diff --git a/data/en_us/videoseg/2020-03-20/api-docs.php b/data/en_us/videoseg/2020-03-20/api-docs.php
index 298f745..235b498 100644
--- a/data/en_us/videoseg/2020-03-20/api-docs.php
+++ b/data/en_us/videoseg/2020-03-20/api-docs.php
@@ -1,33 +1,14 @@
<?php return [
'version' => '1.0',
- 'info' => [
- 'style' => 'RPC',
- 'product' => 'videoseg',
- 'version' => '2020-03-20',
- ],
- 'directories' => [
- [
- 'id' => 208339,
- 'title' => null,
- 'type' => 'directory',
- 'children' => [
- 'SegmentVideoBody',
- ],
- ],
- 'GetAsyncJobResult',
- ],
+ 'info' => ['style' => 'RPC', 'product' => 'videoseg', 'version' => '2020-03-20'],
+ 'directories' => ['GetAsyncJobResult', 'SegmentVideoBody'],
'components' => [
'schemas' => [],
],
'apis' => [
- 'SegmentVideoBody' => [
- 'methods' => [
- 'post',
- ],
- 'schemes' => [
- 'http',
- 'https',
- ],
+ 'GetAsyncJobResult' => [
+ 'methods' => ['post'],
+ 'schemes' => ['http', 'https'],
'security' => [
[
'AK' => [],
@@ -35,88 +16,118 @@
],
'operationType' => 'read',
'deprecated' => false,
- 'systemTags' => [],
+ 'systemTags' => ['operationType' => 'get'],
'parameters' => [
[
- 'name' => 'VideoUrl',
+ 'name' => 'JobId',
'in' => 'formData',
- 'schema' => [
- 'description' => '',
- 'example' => 'http://viapi-test.oss-cn-shanghai.aliyuncs.com/viapi-3.0domepic/videoseg/SegmentVideoBody/SegmentVideoBody1.mp4',
- 'isFileTransferUrl' => true,
- 'required' => true,
- 'type' => 'string',
- ],
+ 'schema' => ['description' => 'The RequestId returned by the asynchronous API operation. You can use this parameter to query the actual result of the asynchronous operation.', 'type' => 'string', 'required' => true, 'example' => 'E75FE679-0303-4DD1-8252-1143B4FA8A27', 'title' => ''],
],
],
'responses' => [
200 => [
'schema' => [
+ 'description' => '1',
+ 'type' => 'object',
'properties' => [
- 'RequestId' => [
- 'description' => '',
- 'example' => '49E2CC28-ED1D-4CC5-854D-7D0AE2B20976',
- 'type' => 'string',
- ],
+ 'RequestId' => ['description' => 'The request ID.', 'type' => 'string', 'example' => '6BD843FB-E7B9-45B6-ADE1-9AB1FF450148', 'title' => ''],
'Data' => [
- 'description' => '',
+ 'description' => 'The returned data.',
+ 'type' => 'object',
'properties' => [
- 'VideoUrl' => [
- 'description' => '',
- 'example' => 'http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/D86DDFBC-B8ED-4780-9E6A-E5BA98D7CC9F.mp4?Expires=1584709406&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=Fx5HVxvRjAMIjWL2OvhTlOO4cC****',
- 'type' => 'string',
- ],
+ 'Status' => ['description' => 'The status of the asynchronous task. Valid values:'."\n"
+ ."\n"
+ .'- QUEUING: The task is queuing.'."\n"
+ ."\n"
+ .'- PROCESSING: The task is being processed.'."\n"
+ ."\n"
+ .'- PROCESS_SUCCESS: The task was processed.'."\n"
+ ."\n"
+ .'- PROCESS_FAILED: The task failed to be processed.'."\n"
+ ."\n"
+ .'- TIMEOUT_FAILED: The task timed out.'."\n"
+ ."\n"
+ .'- LIMIT_RETRY_FAILED: The maximum number of retries was exceeded.', 'type' => 'string', 'example' => 'PROCESS_SUCCESS', 'title' => ''],
+ 'ErrorMessage' => ['description' => 'The error message of the asynchronous task.', 'type' => 'string', 'example' => 'paramsIllegal', 'title' => ''],
+ 'Result' => ['description' => 'The actual result of the asynchronous task.', 'type' => 'string', 'example' => '{\\"VideoUrl\\":\\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/film-summary/49E2CC28-ED1D-4CC5-854D-7D0AE2B20976_rf8mv0.mp4?Expires=1585111875&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=7uE0ppt6uwkdwAFz73PPZN4KG7****\\"}', 'title' => ''],
+ 'ErrorCode' => ['description' => 'The error code of the asynchronous task.', 'type' => 'string', 'example' => 'InvalidParameter', 'title' => ''],
+ 'JobId' => ['description' => 'The asynchronous task ID.', 'type' => 'string', 'example' => '49E2CC28-ED1D-4CC5-854D-7D0AE2B20976', 'title' => ''],
],
- 'type' => 'object',
- ],
- 'Message' => [
- 'description' => '',
+ 'title' => '',
'example' => '',
- 'type' => 'string',
],
],
- 'type' => 'object',
+ 'title' => '',
+ 'example' => '',
],
],
],
'errorCodes' => [
400 => [
- [
- 'errorCode' => 'ParameterError',
- 'errorMessage' => 'The parameter is invalid. Please check again.',
- ],
+ ['errorCode' => 'ParameterError', 'errorMessage' => 'The parameter is invalid. Please check again.', 'description' => 'The parameter is invalid. Please check again.'],
],
403 => [
- [
- 'errorCode' => 'AuthFailed',
- 'errorMessage' => 'An error occurred while performing authorization. Please check your RAM configuration.',
- ],
+ ['errorCode' => 'AuthFailed', 'errorMessage' => 'An error occurred while performing authorization. Please check your RAM configuration.', 'description' => 'An error occurred while performing authorization. Please check your RAM configuration.'],
],
408 => [
- [
- 'errorCode' => 'Timeout',
- 'errorMessage' => 'The request has timed out.',
- ],
+ ['errorCode' => 'Timeout', 'errorMessage' => 'The request has timed out.', 'description' => 'The request has timed out.'],
],
503 => [
- [
- 'errorCode' => 'ServiceUnavailable',
- 'errorMessage' => 'The service is unavailable.',
- ],
+ ['errorCode' => 'ServiceUnavailable', 'errorMessage' => 'The service is unavailable.', 'description' => 'The service is unavailable.'],
],
],
- 'responseDemo' => '[{"type":"json","example":"{\\n \\"RequestId\\": \\"49E2CC28-ED1D-4CC5-854D-7D0AE2B20976\\",\\n \\"Data\\": {\\n \\"VideoUrl\\": \\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/D86DDFBC-B8ED-4780-9E6A-E5BA98D7CC9F.mp4?Expires=1584709406&OSSAccessKeyId=LTAI****************&Signature=Fx5HVxvRjAMIjWL2OvhTlOO4cC****\\"\\n },\\n \\"Message\\": \\"该调用为异步调用,任务已提交成功,请以requestId的值作为jobId参数调用同类目下GetAsyncJobResult接口查询任务执行状态和结果。\\"\\n}","errorExample":""},{"type":"xml","example":"<SegmentVideoBodyResponse>\\n <RequestId>49E2CC28-ED1D-4CC5-854D-7D0AE2B20976</RequestId>\\n <Message>该调用为异步调用,任务已提交成功,请以requestId的值作为jobId参数调用同类目下GetAsyncJobResult接口查询任务执行状态和结果。</Message>\\n</SegmentVideoBodyResponse>","errorExample":""}]',
+ 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"6BD843FB-E7B9-45B6-ADE1-9AB1FF450148\\",\\n \\"Data\\": {\\n \\"Status\\": \\"PROCESS_SUCCESS\\",\\n \\"ErrorMessage\\": \\"paramsIllegal\\",\\n \\"Result\\": \\"{\\\\\\\\\\\\\\"VideoUrl\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/film-summary/49E2CC28-ED1D-4CC5-854D-7D0AE2B20976_rf8mv0.mp4?Expires=1585111875&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=7uE0ppt6uwkdwAFz73PPZN4KG7****\\\\\\\\\\\\\\"}\\",\\n \\"ErrorCode\\": \\"InvalidParameter\\",\\n \\"JobId\\": \\"49E2CC28-ED1D-4CC5-854D-7D0AE2B20976\\"\\n }\\n}","type":"json"}]',
+ 'title' => 'Query asynchronous task results',
+ 'summary' => 'This topic describes the syntax and examples of the GetAsyncJobResult operation for querying asynchronous task results.',
+ 'description' => '## Feature description'."\n"
+ .'After you invoke an asynchronous API operation, the response does not contain the actual result. Save the RequestId from the response, and then invoke GetAsyncJobResult to obtain the actual result.'."\n"
+ ."\n"
+ .'> - Files generated by asynchronous tasks expire after 30 minutes. To retain the files for a longer period, download them to a local server or store them in Object Storage Service (OSS) promptly. For more information about OSS operations, see [Upload objects](~~31886~~).'."\n"
+ .'> - To access Alibaba Cloud Vision Intelligence Open Platform visual AI API operations, learn about API usage, or consult technical issues, join the DingTalk group (23109592) to contact us.'."\n"
+ ."\n\n"
+ .'All API operations in the video segmentation category are asynchronous. You must invoke GetAsyncJobResult to obtain the actual results.',
'requestParamsDescription' => ' ',
- 'responseParamsDescription' => ' ',
- ],
- 'GetAsyncJobResult' => [
- 'methods' => [
- 'post',
+ 'responseParamsDescription' => '## SDK reference'."\n"
+ .'We recommend that you use SDKs to call Alibaba Cloud Vision AI API operations. SDKs support multiple programming languages and allow you to use local files or URLs as file parameters. For more information, see [SDK overview](~~145033~~).',
+ 'extraInfo' => '## Deserialize Result'."\n"
+ .'The deserialized Result is displayed as follows.'."\n"
+ .'```'."\n"
+ .'{'."\n"
+ .' "VideoUrl": "http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/9CDE688A-8FC8-4B8D-8C34-1C3490703F23.mp4?Expires=1585193584&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=z6DQV%2F14CFvammxkgXLcYm0wsW****"'."\n"
+ .'}'."\n"
+ .'```.'."\n"
+ ."\n"
+ .'## Error codes'."\n"
+ .'For error codes of querying asynchronous task results, see [Common error codes](~~159108~~).'."\n"
+ ."\n"
+ .'## Security notice'."\n"
+ .'- Make sure that the images or files you upload comply with applicable laws and regulations.'."\n"
+ .'- Temporary files uploaded through debugging are valid for 1 hour and will be automatically cleaned up and deleted by the system after 24 hours.',
+ 'changeSet' => [
+ ['createdAt' => '2022-04-24T08:15:33.000Z', 'description' => 'Error codes changed'],
],
- 'schemes' => [
- 'http',
- 'https',
+ 'flowControl' => [
+ 'flowControlList' => [
+ ['threshold' => '100', 'countWindow' => 1, 'regionId' => '*', 'api' => 'GetAsyncJobResult'],
+ ],
+ ],
+ 'ramActions' => [
+ [
+ 'operationType' => 'get',
+ 'ramAction' => [
+ 'action' => 'viapi-videoseg:GetAsyncJobResult',
+ 'authLevel' => 'operate',
+ 'actionConditions' => [],
+ 'resources' => [
+ ['validationType' => 'always', 'product' => 'VisualIntelligenceAPI', 'resourceType' => 'All Resource', 'arn' => '*'],
+ ],
+ ],
+ ],
],
+ ],
+ 'SegmentVideoBody' => [
+ 'methods' => ['post'],
+ 'schemes' => ['http', 'https'],
'security' => [
[
'AK' => [],
@@ -124,102 +135,259 @@
],
'operationType' => 'read',
'deprecated' => false,
- 'systemTags' => [
- 'operationType' => 'get',
- ],
+ 'systemTags' => [],
'parameters' => [
[
- 'name' => 'JobId',
+ 'name' => 'VideoUrl',
'in' => 'formData',
- 'schema' => [
- 'description' => '',
- 'example' => 'E75FE679-0303-4DD1-8252-1143B4FA8A27',
- 'required' => true,
- 'type' => 'string',
- ],
+ 'schema' => ['description' => 'The URL of the video. We recommend that you use an OSS URL in the Shanghai region. If the file is stored locally or in an OSS bucket outside the Shanghai region, see [File URL processing](~~155645~~).', 'type' => 'string', 'required' => true, 'isFileTransferUrl' => true, 'example' => 'http://viapi-test.oss-cn-shanghai.aliyuncs.com/viapi-3.0domepic/videoseg/SegmentVideoBody/SegmentVideoBody1.mp4', 'title' => ''],
],
],
'responses' => [
200 => [
'schema' => [
- 'description' => '1',
+ 'type' => 'object',
'properties' => [
- 'RequestId' => [
- 'description' => '',
- 'example' => '6BD843FB-E7B9-45B6-ADE1-9AB1FF450148',
- 'type' => 'string',
- ],
+ 'RequestId' => ['description' => 'The request ID.', 'type' => 'string', 'example' => '49E2CC28-ED1D-4CC5-854D-7D0AE2B20976', 'title' => ''],
'Data' => [
- 'description' => '',
+ 'description' => 'The returned data. After the asynchronous task is executed, invoke the [GetAsyncJobResult](~~607824~~) operation and perform JSON deserialization on the Result field to obtain this data.',
+ 'type' => 'object',
'properties' => [
- 'Status' => [
- 'description' => '',
- 'example' => 'PROCESS_SUCCESS',
- 'type' => 'string',
- ],
- 'ErrorMessage' => [
- 'description' => '',
- 'example' => 'paramsIllegal',
- 'type' => 'string',
- ],
- 'Result' => [
- 'description' => '',
- 'example' => '{\\"VideoUrl\\":\\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/film-summary/49E2CC28-ED1D-4CC5-854D-7D0AE2B20976_rf8mv0.mp4?Expires=1585111875&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=7uE0ppt6uwkdwAFz73PPZN4KG7****\\"}',
- 'type' => 'string',
- ],
- 'ErrorCode' => [
- 'description' => '',
- 'example' => 'InvalidParameter',
- 'type' => 'string',
- ],
- 'JobId' => [
- 'description' => '',
- 'example' => '49E2CC28-ED1D-4CC5-854D-7D0AE2B20976',
- 'type' => 'string',
- ],
+ 'VideoUrl' => ['description' => 'The URL of the output result image.'."\n"
+ .'> This URL is a temporary URL that is valid for 30 minutes. After it expires, the URL is no longer accessible. To save the file for a longer period or permanently, access the URL within 30 minutes and download the file to your own OSS bucket or other storage.', 'type' => 'string', 'example' => 'http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/D86DDFBC-B8ED-4780-9E6A-E5BA98D7CC9F.mp4?Expires=1584709406&OSSAccessKeyId=LTAI****************&Signature=Fx5HVxvRjAMIjWL2OvhTlOO4cC****', 'title' => ''],
],
- 'type' => 'object',
+ 'title' => '',
+ 'example' => '',
],
+ 'Message' => ['description' => 'The message returned after the asynchronous task is submitted.', 'type' => 'string', 'example' => '该调用为异步调用,任务已提交成功,请以requestId的值作为jobId参数调用同类目下GetAsyncJobResult接口查询任务执行状态和结果。', 'title' => ''],
],
- 'type' => 'object',
+ 'description' => '',
+ 'title' => '',
+ 'example' => '',
],
],
],
'errorCodes' => [
400 => [
- [
- 'errorCode' => 'ParameterError',
- 'errorMessage' => 'The parameter is invalid. Please check again.',
- ],
+ ['errorCode' => 'ParameterError', 'errorMessage' => 'The parameter is invalid. Please check again.', 'description' => 'The parameter is invalid. Please check again.'],
],
403 => [
- [
- 'errorCode' => 'AuthFailed',
- 'errorMessage' => 'An error occurred while performing authorization. Please check your RAM configuration.',
- ],
+ ['errorCode' => 'AuthFailed', 'errorMessage' => 'An error occurred while performing authorization. Please check your RAM configuration.', 'description' => 'An error occurred while performing authorization. Please check your RAM configuration.'],
],
408 => [
- [
- 'errorCode' => 'Timeout',
- 'errorMessage' => 'The request has timed out.',
- ],
+ ['errorCode' => 'Timeout', 'errorMessage' => 'The request has timed out.', 'description' => 'The request has timed out.'],
],
503 => [
- [
- 'errorCode' => 'ServiceUnavailable',
- 'errorMessage' => 'The service is unavailable.',
- ],
+ ['errorCode' => 'ServiceUnavailable', 'errorMessage' => 'The service is unavailable.', 'description' => 'The service is unavailable.'],
],
],
- 'responseDemo' => '[{"type":"json","example":"{\\n \\"RequestId\\": \\"6BD843FB-E7B9-45B6-ADE1-9AB1FF450148\\",\\n \\"Data\\": {\\n \\"Status\\": \\"PROCESS_SUCCESS\\",\\n \\"ErrorMessage\\": \\"paramsIllegal\\",\\n \\"Result\\": \\"{\\\\\\\\\\\\\\"VideoUrl\\\\\\\\\\\\\\":\\\\\\\\\\\\\\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/film-summary/49E2CC28-ED1D-4CC5-854D-7D0AE2B20976_rf8mv0.mp4?Expires=1585111875&OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&Signature=7uE0ppt6uwkdwAFz73PPZN4KG7****\\\\\\\\\\\\\\"}\\",\\n \\"ErrorCode\\": \\"InvalidParameter\\",\\n \\"JobId\\": \\"49E2CC28-ED1D-4CC5-854D-7D0AE2B20976\\"\\n }\\n}","errorExample":""},{"type":"xml","example":"<RequestId>6BD843FB-E7B9-45B6-ADE1-9AB1FF450148</RequestId>\\n<Data>\\n <Status>PROCESS_SUCCESS</Status>\\n <JobId>9CDE688A-8FC8-4B8D-8C34-1C3490703F23</JobId>\\n <Result>{\\"VideoUrl\\":\\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/9CDE688A-8FC8-4B8D-8C34-1C3490703F23.mp4?Expires=1585193584&amp;OSSAccessKeyId=LTAI4FoLmvQ9urWXgSRp****&amp;Signature=z6DQV%2F14CFvammxkgXLcYm0wsW****\\"}</Result>\\n</Data>","errorExample":""}]',
+ 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"49E2CC28-ED1D-4CC5-854D-7D0AE2B20976\\",\\n \\"Data\\": {\\n \\"VideoUrl\\": \\"http://algo-app-aic-vd-cn-shanghai-prod.oss-cn-shanghai.aliyuncs.com/video-human-segmentation/D86DDFBC-B8ED-4780-9E6A-E5BA98D7CC9F.mp4?Expires=1584709406&OSSAccessKeyId=LTAI****************&Signature=Fx5HVxvRjAMIjWL2OvhTlOO4cC****\\"\\n },\\n \\"Message\\": \\"该调用为异步调用,任务已提交成功,请以requestId的值作为jobId参数调用同类目下GetAsyncJobResult接口查询任务执行状态和结果。\\"\\n}","type":"json"}]',
+ 'title' => 'Video portrait segmentation',
+ 'summary' => 'This topic describes the syntax and examples of the SegmentVideoBody operation for video portrait segmentation.',
+ 'description' => '## Feature description'."\n"
+ .'The video portrait segmentation feature parses an input video and returns the mask of the portrait region as a video sequence.'."\n"
+ ."\n"
+ .'> - You can join [online consultation](https://www.aliyun.com/core/online-consult?from=aZgW6LJHr2) to get online help.'."\n"
+ .'>- You can try this feature for free on the Vision Intelligence Open Platform. Click [Try Now](https://vision.aliyun.com/experience/detail?&tagName=videoseg&children=SegmentVideoBody) to experience this feature or purchase it online.'."\n"
+ .'>- For questions about Alibaba Cloud Vision Intelligence Open Platform visual AI API integration or usage, join the DingTalk group (23109592) to contact us.'."\n"
+ ."\n"
+ .'## Integration guide'."\n"
+ .'1. Register an Alibaba Cloud account: Go to the [Alibaba Cloud official website](https://www.aliyun.com), click **Register Now** in the upper-right corner, and follow the instructions to complete the registration.'."\n"
+ .'2. Activate the service: Make sure you have activated the [video segmentation service](https://vision.aliyun.com/videoseg). If you have not activated the service, [activate it now](https://common-buy.aliyun.com/?commodityCode=viapi_videoseg_public_cn#/open).'."\n"
+ .'3. Create an AccessKey: Make sure you have [created an AccessKey](~~175144~~). If you are using a RAM user AccessKey, grant the AliyunVIAPIFullAccess permission to the RAM user. For more information, see [RAM authorization](~~145025~~).'."\n"
+ .'4. Online debugging (optional): You can use [OpenAPI Explorer](https://next.api.aliyun.com/api/videoseg/2020-03-20/SegmentVideoBody?lang=JAVA&sdkStyle=dara&params=%7B%22VideoUrl%22%3A%22http%3A%2F%2Fviapi-test.oss-cn-shanghai.aliyuncs.com%2Fviapi-3.0domepic%2Fvideoseg%2FSegmentVideoBody%2FSegmentVideoBody1.mp4%22%7D&tab=DEMO) to debug this feature online, view complete sample code and SDK dependency information, or download the complete project.'."\n"
+ .'5. Development integration steps: '."\n"
+ .'- Select the SDK language you want to use from the [SDK overview](~~145033~~).'."\n"
+ .'- Find the SDK package for the video segmentation (videoseg) AI category in the corresponding SDK documentation and install it.'."\n"
+ .'- Modify the sample code provided in the References as needed and invoke it.'."\n"
+ ."\n"
+ .'6. Sample code: For sample code in common languages for this feature, see [Video portrait segmentation sample code](~~610206~~). For sample code for querying asynchronous task results in common languages, see [Query asynchronous task result sample code](~~607974~~).'."\n"
+ .'7. Direct client invocations: Common client invocation methods for this feature include the following.'."\n"
+ .'- [Direct invocation from web frontend](~~467779~~)'."\n"
+ .'- [Direct invocation from mini programs](~~467780~~)'."\n"
+ .'- [Direct invocation from Android](~~467781~~)'."\n"
+ .'- [Direct invocation from iOS](~~467782~~).'."\n"
+ ."\n"
+ .'## Input limits'."\n"
+ ."\n"
+ .'- Video format: MP4, AVI, FLV, or MOV.'."\n"
+ .'- Video size: up to 1 GB.'."\n"
+ .'- The total number of frames in the video cannot exceed 2,000.'."\n"
+ .'- The URL cannot contain Chinese characters.'."\n"
+ ."\n"
+ .'## Security notice'."\n"
+ .'- Make sure that the uploaded images or files comply with applicable laws and regulations.'."\n"
+ .'- Temporary files uploaded through the debugging experience are valid for 1 hour and are automatically deleted by the system after 24 hours.'."\n"
+ ."\n"
+ .'## Billable methods'."\n"
+ .'For information about the billable methods and pricing of video portrait segmentation, see [Billing overview](~~202488~~).'."\n"
+ ."\n"
+ .'> The following debugging operation is a paid operation.'."\n"
+ ."\n"
+ .'## Call procedure'."\n"
+ .'This feature is asynchronous and requires two steps.'."\n"
+ ."\n"
+ .'Step 1: Call the SegmentVideoBody operation to submit a task. If the request is successful, a task ID is returned.'."\n"
+ ."\n"
+ .'Step 2: Call the [GetAsyncJobResult](~~607824~~) operation to query the result based on the task ID. If the task is still being processed, wait a moment and try again. Do not submit duplicate tasks while the same task is still being processed.',
'requestParamsDescription' => ' ',
- 'responseParamsDescription' => ' ',
+ 'responseParamsDescription' => '## Query results'."\n"
+ .'This operation is asynchronous and does not return the actual result. You need to call the GetAsyncJobResult operation with the returned RequestId to obtain the actual result. For more information, see [GetAsyncJobResult](~~607824~~).'."\n"
+ ."\n"
+ .'## SDK reference'."\n"
+ .'For the video portrait segmentation feature under the Alibaba Cloud Vision AI video segmentation category, we recommend that you use the SDK. The SDK supports multiple programming languages. When making calls, select the SDK package for the video segmentation (videoseg) AI category. File parameters can be passed as local files or URLs through the SDK. For more information, see [SDK overview](~~145033~~).'."\n"
+ ."\n"
+ .'## Sample code'."\n"
+ .'For sample code in common languages for this feature, see [Video portrait segmentation sample code](~~610206~~). For sample code for querying asynchronous task results in common languages, see [Query asynchronous task result sample code](~~607974~~).',
+ 'changeSet' => [
+ ['createdAt' => '2022-10-17T02:07:53.000Z', 'description' => 'Response parameters changed'],
+ ],
+ 'flowControl' => [
+ 'flowControlList' => [
+ ['threshold' => '100', 'countWindow' => 1, 'regionId' => '*', 'api' => 'SegmentVideoBody'],
+ ],
+ ],
+ 'ramActions' => [
+ [
+ 'operationType' => '',
+ 'ramAction' => [
+ 'action' => 'viapi-videoseg:SegmentVideoBody',
+ 'authLevel' => 'operate',
+ 'actionConditions' => [],
+ 'resources' => [
+ ['validationType' => 'always', 'product' => 'VisualIntelligenceAPI', 'resourceType' => 'All Resource', 'arn' => '*'],
+ ],
+ ],
+ ],
+ ],
],
],
'endpoints' => [
+ ['regionId' => 'cn-shanghai', 'regionName' => 'China (Shanghai)', 'areaId' => 'asiaPacific', 'areaName' => 'Asia Pacific', 'public' => 'videoseg.cn-shanghai.aliyuncs.com', 'endpoint' => 'videoseg.cn-shanghai.aliyuncs.com', 'vpc' => 'videoseg-vpc.cn-shanghai.aliyuncs.com'],
+ ],
+ 'errorCodes' => [
+ ['code' => 'AuthFailed', 'message' => 'An error occurred while performing authorization. Please check your RAM configuration.', 'http_code' => 403, 'description' => 'An error occurred while performing authorization. Please check your RAM configuration.'],
+ ['code' => 'EntityNotExist.Role', 'message' => '没有Ram权限,请联系主账号给你添加AliyunVIAPIFullAccess权限,操作流程可参考https://help.aliyun.com/document_detail/145025.htm', 'http_code' => 403, 'description' => ''],
+ ['code' => 'IllegalUrlParameter', 'message' => 'Url不合法,请检查url能否正常打开', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InternalError', 'message' => 'An error occurred to the algorithm service.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Algo', 'message' => 'An algorithm error occurred.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Busy', 'message' => 'Server busy.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Decode', 'message' => 'Failed to decode the image.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Env', 'message' => 'Failed to initilize the environment.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Model', 'message' => 'Failed to load the model.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Process', 'message' => 'An error occurred during inference.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Remote', 'message' => 'The request processing has failed due to some unknown error.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Server', 'message' => 'The request processing has failed due to some unknown error.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalError.Timeout', 'message' => '算法服务报错,请稍后重试', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InternalServerError', 'message' => 'A server error occurred while processing your request.', 'http_code' => 500, 'description' => ''],
+ ['code' => 'InvalidAccessKeyId.Inactive', 'message' => 'AccessKeyId非法,请检查AccessKeyId是否被禁用,或者AccessKeyId和AccessKeySecret是否填写正确。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidAccessKeyId.NotFound', 'message' => 'AccessKeyId未找到,请检查AccessKeyId和AccessKeySecret是否填写正确。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidAccessKeySecret', 'message' => 'AccessKeyId或AccessKeySecret填写错误,请检查AccessKeyId和AccessKeySecret是否填写正确。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidAction.NotFound', 'message' => '能力未找到,请检查类目与能力是否匹配,检查访问域名与能力是否匹配,关于访问域名可参考:https://help.aliyun.com/document_detail/143103.htm。SDK接入请参考:https://help.aliyun.com/document_detail/145033.html,选择合适编程语言根据实例代码作相关修改进行接入。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidApi.ForbiddenInvoke', 'message' => '调用受限,请检查您调用的能力是否为受限能力,受限能力需要在控制台https://vision.console.aliyun.com/找到相应能力申请经过审批之后才能调用。如非上述情况,请检查账号是否欠费', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidApi.NotPurchase', 'message' => '产品未开通,请开通产品:https://common-buy.aliyun.com/?commodityCode=viapi_videoseg_public_cn#/open', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidApi.OutOfService', 'message' => '产品未开通,请开通产品:https://common-buy.aliyun.com/?commodityCode=viapi_videoseg_public_cn#/open', 'http_code' => 403, 'description' => ''],
+ ['code' => 'InvalidFile.Category', 'message' => 'The file content category does not meet requirements.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Content', 'message' => 'The content format of the image or video is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Decode', 'message' => 'Failed to decode the file.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Download', 'message' => 'Failed to download the file.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Region', 'message' => 'The URL format of the file is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Resolution', 'message' => 'The resolution of the image or video is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Type', 'message' => 'The file type of the image or video is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.Unsafe', 'message' => 'Risky file URL.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidFile.URL', 'message' => 'The URL format of the file is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Content', 'message' => '请参考算法文档检查图片内容,更换包含符合算法要求的', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Decode', 'message' => '请检查图片是否能够正常打开', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Download', 'message' => '图片无法下载,请检查链接是否可访问和本地网络情况 - 非上海OSS图片链接请参考:https://help.aliyun.com/document_detail/155645.html', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.NotFoundFace', 'message' => '图像中没找到人脸,请检查您的图像中是否包含人脸或人脸太小', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.REGION', 'message' => '图片链接地域不对,非上海OSS图片链接请参考:https://help.aliyun.com/document_detail/155645.html', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Resolution', 'message' => '文件分辨率超出限制,请检查文件分辨率和内容,修改文件分辨率后重试', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Timeout', 'message' => '图片下载超时,请检查链接是否可访问和本地网络情况', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.Type', 'message' => '图片类型错误,请检查图片类型 - 请参考算法API文档,使用算法支持的图片类型', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImage.URL', 'message' => 'The image URL is invalid.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidImageType', 'message' => 'Invalid image type.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidParameter', 'message' => 'Invalid parameter value.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidParameter.BadRequest', 'message' => 'The request parameter or the data has an error.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidParameter.Format', 'message' => 'The entry format is incorrect.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidParameter.NotFound', 'message' => '参数错误,请根据算法API文档和报错Message检查参数值。是否参数值前后多了空格或者其他特殊字符等。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidParameter.TooLarge', 'message' => '参数错误,文件大小超出限制,请参考算法API文档调整文件大小', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidRamRole', 'message' => '没有Ram权限,请联系主账号给你添加AliyunVIAPIFullAccess权限,操作流程可参考https://help.aliyun.com/document_detail/145025.htm', 'http_code' => 403, 'description' => ''],
+ ['code' => 'InvalidResult', 'message' => '参数错误,请参考文档检查参数值,检查文件内容。请检查是否图片内容不完整或者太模糊等。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidTimeStamp.Expired', 'message' => 'The timestamp has expired. Please update the timestamp.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'InvalidVersion', 'message' => 'Specified parameter Version is not valid', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingAccessKeyId', 'message' => 'AccessKeyId未填写,请检查AccessKeyId和AccessKeySecret是否填写正确。', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingFileURL', 'message' => 'FileURL is required for this operation.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingImageURL', 'message' => 'ImageURL is required for this operation.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingLimit', 'message' => 'Limit is required for this operation', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingParameter', 'message' => 'A required parameter is not specified.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'MissingTasks', 'message' => 'Tasks is required for this operation.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'ParameterError', 'message' => 'The parameter is invalid. Please check again.', 'http_code' => 400, 'description' => 'The parameter is invalid. Please check again.'],
+ ['code' => 'ServiceUnavailable', 'message' => 'The service is unavailable.', 'http_code' => 503, 'description' => 'The service is unavailable.'],
+ ['code' => 'SignatureDoesNotMatch', 'message' => '签名不正确,请重新计算签名。关于签名可参考文档:https://help.aliyun.com/document_detail/144904.html', 'http_code' => 400, 'description' => ''],
+ ['code' => 'SignatureNonceUsed', 'message' => '签名已经被使用过,请重新计算签名。关于签名可参考文档:https://help.aliyun.com/document_detail/144904.html', 'http_code' => 400, 'description' => ''],
+ ['code' => 'Throttling', 'message' => 'The request was denied due to QPS limits.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'Throttling.User', 'message' => 'The request was denied due to QPS limits.', 'http_code' => 400, 'description' => ''],
+ ['code' => 'Timeout', 'message' => 'The request has timed out.', 'http_code' => 408, 'description' => 'The request has timed out.'],
+ ['code' => 'Unauthorized', 'message' => '没有Ram权限,请联系主账号给你添加AliyunVIAPIFullAccess权限,操作流程可参考https://help.aliyun.com/document_detail/145025.htm', 'http_code' => 400, 'description' => ''],
+ ],
+ 'changeSet' => [
[
- 'regionId' => 'cn-shanghai',
- 'endpoint' => 'videoseg.cn-shanghai.aliyuncs.com',
+ 'apis' => [
+ ['description' => 'Response parameters changed', 'api' => 'SegmentGreenScreenVideo'],
+ ['description' => 'Response parameters changed', 'api' => 'SegmentHalfBody'],
+ ['description' => 'Response parameters changed', 'api' => 'SegmentVideoBody'],
+ ],
+ 'createdAt' => '2022-10-17T02:08:02.000Z',
+ 'description' => '修改异步任务Message为可见',
+ ],
+ [
+ 'apis' => [
+ ['description' => 'Error codes changed', 'api' => 'GetAsyncJobResult'],
+ ],
+ 'createdAt' => '2022-04-24T08:16:35.000Z',
+ 'description' => '调整GetAsyncJobResult单用户调用频率',
+ ],
+ ],
+ 'flowControl' => [
+ 'flowControlList' => [
+ ['threshold' => '100', 'countWindow' => 1, 'regionId' => '*', 'api' => 'GetAsyncJobResult'],
+ ['threshold' => '100', 'countWindow' => 1, 'regionId' => '*', 'api' => 'SegmentVideoBody'],
+ ],
+ ],
+ 'ram' => [
+ 'productCode' => 'VisualIntelligenceAPI',
+ 'productName' => 'Visual Intelligence API',
+ 'ramCodes' => ['viapi-imageseg', 'viapi-imageaudit', 'viapi-ocr', 'viapi-objectdet', 'viapi-imageenhan', 'viapi-videorecog', 'viapi-imageprocess', 'viapi', 'viapi-ekyc', 'viapi-imgsearch', 'viapi-goodstech', 'viapi-facebody', 'viapi-threedvision', 'viapi-videoenhan', 'viapi-imagerecog', 'viapi-videoseg', 'viapi-regen', 'viapi-aigen'],
+ 'ramLevel' => 'SERVICE',
+ 'ramConditions' => [],
+ 'ramActions' => [
+ [
+ 'apiName' => 'GetAsyncJobResult',
+ 'description' => '',
+ 'operationType' => 'get',
+ 'ramAction' => [
+ 'action' => 'viapi-videoseg:GetAsyncJobResult',
+ 'authLevel' => 'operate',
+ 'actionConditions' => [],
+ 'resources' => [
+ ['validationType' => 'always', 'product' => 'VisualIntelligenceAPI', 'resourceType' => 'All Resource', 'arn' => '*'],
+ ],
+ ],
+ ],
+ [
+ 'apiName' => 'SegmentVideoBody',
+ 'description' => '',
+ 'operationType' => '',
+ 'ramAction' => [
+ 'action' => 'viapi-videoseg:SegmentVideoBody',
+ 'authLevel' => 'operate',
+ 'actionConditions' => [],
+ 'resources' => [
+ ['validationType' => 'always', 'product' => 'VisualIntelligenceAPI', 'resourceType' => 'All Resource', 'arn' => '*'],
+ ],
+ ],
+ ],
],
+ 'resourceTypes' => [],
],
];