图像识别
⚠️ 测试中
▼
Authorization
在 Header 添加参数 Authorization,其值为 Bearer 之后拼接 Token
示例:
Authorization: Bearer ********************
请求参数
Header 参数
Content-Type
string
可选
示例: application/json
Authorization
string
可选
示例: Bearer {{YOUR_API_KEY}}
Body 参数 application/json
image
string
必需
待识别的图片 支持传入图片Base64编码或图片URL(确保可访问)图片格式支持.jpg / .jpeg / .png 图片文件大小不能超过10MB,图片宽高尺寸不小于300px,图片宽高比介于1:2.5 ~ 2.5:1之间
示例
{
"image": "https://example.com/image.jpg"
}
请求示例代码
curl --location --request POST 'https://api.quickrouter.ai/kling/v1/videos/image-recognize' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data-raw '{
"image": "https://example.com/image.jpg"
}'
var myHeaders = new Headers();
myHeaders.append("Authorization", "Bearer YOUR_API_KEY");
myHeaders.append("Content-Type", "application/json");
var raw = JSON.stringify({
"image": "https://example.com/image.jpg"
});
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: raw,
redirect: 'follow'
};
fetch("https://api.quickrouter.ai/kling/v1/videos/image-recognize", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
import http.client
import json
conn = http.client.HTTPSConnection("api.quickrouter.ai")
payload = json.dumps({
"image": "https://example.com/image.jpg"
})
headers = {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
}
conn.request("POST", "/kling/v1/videos/image-recognize", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
返回响应
响应参数 application/json
object
string
可选
示例
{}