通义多模态HMEL翻译获取翻译结果
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
当前API暂无授权信息透出。
请求语法
POST /anytrans/translate/html/get HTTP/1.1
请求参数
名称 | 类型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
workspaceId | string | 是 | 当前请求所使用的百炼业务空间 id | llm-kqtrcpdee4xm29xx |
taskId | string | 否 | html 翻译任务 id | 868c2fdd-96c2-4546-96d2-a259b8f35252 |
返回参数
示例
正常返回示例
JSON
格式
{
"code": "success",
"message": "success",
"requestId": "04B53310-CB1A-14B4-AC85-26C154D8366A",
"success": true,
"httpStatusCode": 200,
"data": {
"translation": "<!DOCTYPE html>\n\n<html lang=\"zh-CN\">\n<head>\n<meta charset=\"utf-8\"/>\n<meta content=\"width=device-width, initial-scale=1.0\" name=\"viewport\"/>\n<title>My First Webpage</title>\n</head>\n<body>\n<h1>Welcome to my webpage!</h1>\n<p>This is a simple HTML page.</p>\n<p>Learning HTML is the first step to entering web development.</p>\n<a href=\"https://www.example.com\">Click here to visit the sample website</a>\n</body>\n</html>",
"usage": {
"inputTokens": 22,
"outputTokens": 19,
"totalTokens": 41
}
}
}
错误码
HTTP status code | 错误码 | 错误信息 |
---|---|---|
400 | IdempotentParameterMismatch | The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical. |
访问错误中心查看更多错误码。