创建数字人
<pre><code class="language-text">数字人-创建</code></pre>
<h4>接口URL</h4>
<p>> /api/v1/ai/avatar/create</p>
<h4>请求方式</h4>
<p>> POST</p>
<h4>请求Query参数</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>cv</td>
<td>1.1.0</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>cp</td>
<td>a</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>ci</td>
<td>999999</td>
<td>String</td>
<td>是</td>
<td>-</td>
</tr>
</tbody>
</table>
<h4>请求Body参数</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>token</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>登录令牌</td>
</tr>
<tr>
<td>uid</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>用户标识</td>
</tr>
<tr>
<td>deviceId</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>-</td>
</tr>
<tr>
<td>params</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>数据集</td>
</tr>
</tbody>
</table>
<h4>params参数说明</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>width</td>
<td>-</td>
<td>int</td>
<td>是</td>
<td>视频宽,最大不能超过1080,最小不能小于1</td>
</tr>
<tr>
<td>height</td>
<td>-</td>
<td>int</td>
<td>是</td>
<td>视频高,最大不能超过1920,最小不能小于1</td>
</tr>
<tr>
<td>createType</td>
<td>-</td>
<td>string</td>
<td>是</td>
<td>生成类型,sys:系统预设,user:用户自定义</td>
</tr>
<tr>
<td>speakerId</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>数字人标识,createType为sys时,该字段必传</td>
</tr>
<tr>
<td>avatarWidth</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>数字人宽度</td>
</tr>
<tr>
<td>avatarHeight</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>数字人高度</td>
</tr>
<tr>
<td>avatarX</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>数字人x轴坐标,相对于视频左上角</td>
</tr>
<tr>
<td>avatarY</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>数字人y轴坐标,相对于视频左上角</td>
</tr>
<tr>
<td>bgImage</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>背景图url</td>
</tr>
<tr>
<td>bgImageWidth</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>背景图宽度,bgImage不为空是,该字段必传</td>
</tr>
<tr>
<td>bgImageHeight</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>背景图高度,bgImage不为空是,该字段必传</td>
</tr>
<tr>
<td>bgImageX</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>背景图x轴坐标,相对于视频左上角</td>
</tr>
<tr>
<td>bgImageY</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>背景图y轴坐标,相对于视频左上角</td>
</tr>
<tr>
<td>audioUrl</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>音频url</td>
</tr>
<tr>
<td>audioDuration</td>
<td>-</td>
<td>int</td>
<td>否</td>
<td>音频时长,单位秒,audioUrl不为空是,该字段必传</td>
</tr>
<tr>
<td>customImage</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>自定义数字人图片createType为user时,该字段必传</td>
</tr>
<tr>
<td>extInfo</td>
<td>-</td>
<td>string</td>
<td>否</td>
<td>扩展信息</td>
</tr>
</tbody>
</table>
<h4>返回参数说明</h4>
<table>
<thead>
<tr>
<th>参数名</th>
<th>示例值</th>
<th>参数类型</th>
<th>是否必填</th>
<th>参数描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>taskId</td>
<td>-</td>
<td>String</td>
<td>-</td>
<td>创建任务id</td>
</tr>
</tbody>
</table>
<h5>返回示例</h5>
<pre><code>{
&quot;taskId&quot;: &quot;&quot;
}</code></pre>
<h5>失败返回示例</h5>
<pre><code>{
&quot;code&quot;: 1001,
&quot;reason&quot;: &quot;请求参数错误&quot;,
&quot;extInfo&quot;: null
}</code></pre>