Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

Retrieve fresh output from the original Video task

Generated from the checked-in source. Do not edit this reference by hand.

POST /api/v1/workspaces/{workspace}/tasks/{task}/results/{kind}/refresh

Explicit workspace Write action. Derives the original inference key and immutable Provider/account/model/channel binding from the actor-visible saved task; clients cannot choose replacements. Current original key grants and source policy remain required; revoked or expired keys never regain action authority through history. No generation, automatic retry or composer configuration is used. Rechecks actor visibility and grants after upstream work. Saved GET, cached artifact content, upstream refresh and fresh delivery remain distinct. Queries the original task once, then performs bounded authorized binary retrieval. Does not rewrite expired/deleted cached references. A fresh URL does not prove durable media availability; missing result404, Provider gone/unavailable502 and timeout504 remain explicit. The server resolves the organization from the authorized workspace. Foreign or missing workspaces return 404. The compatibility route remains supported with identical payload, owner, revision and replay semantics.

Operation: retrieveFreshGenerationsTaskResultByWorkspace.

Use the credential and permission scope described above. Each object below is an alternative; schemes within one object are required together.

JSON
[
{
"bearerAuth": []
}
]

Set NIU_ORIGIN to your installation origin (without /v1). Replace path, query and header placeholders with the required values. Query examples use curl 7.87 or newer to encode values with --url-query. Use the credential scope described above; a bearer token must have the authority required by this operation.

Shell
curl --fail-with-body -X POST "$NIU_ORIGIN/api/v1/workspaces/{workspace}/tasks/{task}/results/{kind}/refresh" \
-H "Authorization: Bearer $NIU_BEARER_TOKEN"

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: path. Required.

JSON
{
"type": "string",
"format": "uuid"
}

Location: path. Required.

JSON
{
"type": "string",
"enum": [
"video",
"last_frame"
]
}

No request body is declared.

Bounded media bytes

Content type: video/mp4.

JSON
{
"type": "string",
"format": "binary"
}

Content type: video/webm.

JSON
{
"type": "string",
"format": "binary"
}

Content type: image/png.

JSON
{
"type": "string",
"format": "binary"
}

Content type: image/jpeg.

JSON
{
"type": "string",
"format": "binary"
}

Invalid kind or request

Sign-in required

Workspace Write or original-key permission denied

Task missing, actor-private, or original key no longer available

Original Provider binding changed or query already claimed

Upstream query or result delivery failed

Storage or bounded delivery unavailable

Upstream query or delivery timed out

Explicit workspace Write action. Derives the original inference key and immutable Provider/account/model/channel binding from the actor-visible saved task; clients cannot choose replacements. Current original key grants and source policy remain required; revoked or expired keys never regain action authority through history. No generation, automatic retry or composer configuration is used. Rechecks actor visibility and grants after upstream work. Saved GET, cached artifact content, upstream refresh and fresh delivery remain distinct. Queries the original task once, then performs bounded authorized binary retrieval. Does not rewrite expired/deleted cached references. A fresh URL does not prove durable media availability; missing result404, Provider gone/unavailable502 and timeout504 remain explicit. The server resolves the organization from the authorized workspace. Foreign or missing workspaces return 404. The compatibility route remains supported with identical payload, owner, revision and replay semantics.

Supported scope: implemented