读取指定制品版本
curl --request GET \
--url http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id} \
--header 'Authorization: Bearer <token>'import requests
url = "http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"mediaResolution": {
"level": "MEDIA_RESOLUTION_UNSPECIFIED",
"numTokens": 123
},
"codeExecutionResult": {
"outcome": "OUTCOME_UNSPECIFIED",
"output": "<string>",
"id": "<string>"
},
"executableCode": {
"code": "<string>",
"language": "LANGUAGE_UNSPECIFIED",
"id": "<string>"
},
"fileData": {
"displayName": "<string>",
"fileUri": "<string>",
"mimeType": "<string>"
},
"functionCall": {
"id": "<string>",
"args": {},
"name": "<string>",
"partialArgs": [
{
"boolValue": true,
"jsonPath": "<string>",
"nullValue": "NULL_VALUE",
"numberValue": 123,
"stringValue": "<string>",
"willContinue": true
}
],
"willContinue": true
},
"functionResponse": {
"willContinue": true,
"scheduling": "SCHEDULING_UNSPECIFIED",
"parts": [
{
"inlineData": {
"mimeType": "<string>",
"data": "<string>",
"displayName": "<string>"
},
"fileData": {
"fileUri": "<string>",
"mimeType": "<string>",
"displayName": "<string>"
}
}
],
"id": "<string>",
"name": "<string>",
"response": {}
},
"inlineData": {
"data": "<string>",
"displayName": "<string>",
"mimeType": "<string>"
},
"text": "<string>",
"thought": true,
"thoughtSignature": "<string>",
"videoMetadata": {
"endOffset": "<string>",
"fps": 123,
"startOffset": "<string>"
},
"toolCall": {
"id": "<string>",
"toolType": "TOOL_TYPE_UNSPECIFIED",
"args": {}
},
"toolResponse": {
"id": "<string>",
"toolType": "TOOL_TYPE_UNSPECIFIED",
"response": {}
},
"partMetadata": {}
}{
"detail": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}制品
读取指定制品版本
按版本号读取制品内容;不存在时返回 404
GET
/
apps
/
{app_name}
/
users
/
{user_id}
/
sessions
/
{session_id}
/
artifacts
/
{artifact_name}
/
versions
/
{version_id}
读取指定制品版本
curl --request GET \
--url http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id} \
--header 'Authorization: Bearer <token>'import requests
url = "http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('http://localhost:8000/apps/{app_name}/users/{user_id}/sessions/{session_id}/artifacts/{artifact_name}/versions/{version_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"mediaResolution": {
"level": "MEDIA_RESOLUTION_UNSPECIFIED",
"numTokens": 123
},
"codeExecutionResult": {
"outcome": "OUTCOME_UNSPECIFIED",
"output": "<string>",
"id": "<string>"
},
"executableCode": {
"code": "<string>",
"language": "LANGUAGE_UNSPECIFIED",
"id": "<string>"
},
"fileData": {
"displayName": "<string>",
"fileUri": "<string>",
"mimeType": "<string>"
},
"functionCall": {
"id": "<string>",
"args": {},
"name": "<string>",
"partialArgs": [
{
"boolValue": true,
"jsonPath": "<string>",
"nullValue": "NULL_VALUE",
"numberValue": 123,
"stringValue": "<string>",
"willContinue": true
}
],
"willContinue": true
},
"functionResponse": {
"willContinue": true,
"scheduling": "SCHEDULING_UNSPECIFIED",
"parts": [
{
"inlineData": {
"mimeType": "<string>",
"data": "<string>",
"displayName": "<string>"
},
"fileData": {
"fileUri": "<string>",
"mimeType": "<string>",
"displayName": "<string>"
}
}
],
"id": "<string>",
"name": "<string>",
"response": {}
},
"inlineData": {
"data": "<string>",
"displayName": "<string>",
"mimeType": "<string>"
},
"text": "<string>",
"thought": true,
"thoughtSignature": "<string>",
"videoMetadata": {
"endOffset": "<string>",
"fps": 123,
"startOffset": "<string>"
},
"toolCall": {
"id": "<string>",
"toolType": "TOOL_TYPE_UNSPECIFIED",
"args": {}
},
"toolResponse": {
"id": "<string>",
"toolType": "TOOL_TYPE_UNSPECIFIED",
"response": {}
},
"partMetadata": {}
}{
"detail": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}使用保存制品时返回的版本号,或先查询版本列表。成功返回该版本的
Part 内容;制品或该版本不存在时返回 404
内容可能位于 text 或 inlineData。版本的 URI、MIME 类型与自定义元数据通过获取制品版本元数据单独读取授权
本地未配置网关时可不提供;云部署使用 Runtime API Key 或部署要求的用户池 JWT,不能使用模型 API Key
路径参数
应用名称,CLI 部署版为 harness_agent
用户 ID
会话 ID
制品名称
制品版本号
响应
Part · object | null
请求成功
Show child attributes
Show child attributes
代码执行结果
Show child attributes
Show child attributes
可执行代码
Show child attributes
Show child attributes
通过 URI 引用的文件内容
Show child attributes
Show child attributes
模型请求执行的函数调用
Show child attributes
Show child attributes
函数执行结果
Show child attributes
Show child attributes
内嵌二进制内容,data 使用 Base64 编码
Show child attributes
Show child attributes
文本内容
是否为思考内容
用于后续调用的思考签名
视频元数据
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
最后修改于 2026年9月19日