get_download_url

Get download URL

A short-lived attachment URL for a ready generation or verified upload, on this server's own API host. A set (a group: a carousel, a workflow run's pictures) returns one ordered ZIP of its members. Minted at the press; ask again rather than caching it. With as: "image" the picture itself comes back too, as image content the client can save: a clip's poster frame, a set's ready pictures in order (up to ten), nothing for a sound. That is how to put Kuro pictures into a page or an artifact when the sandbox cannot download. If the sandbox refuses that host, ask the user (or whoever manages their workspace) to allow it, and do not try other hosts.

Scope

Behaviour

Read-only
Reads the caller's own account and changes nothing.
Stays in the account
Stays inside the caller's private Kuro account: any media provider it calls acts on Kuro's account, and the result is visible to no one else.
Idempotent
Calling it again with the same arguments has no further effect.

Inputs

Example call

A tools/call request with the required arguments only, each a placeholder read off the schema. Replace them before sending.

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "get_download_url",
    "arguments": {
      "reference": {
        "type": "upload",
        "upload_id": "00000000-0000-4000-8000-000000000000"
      }
    }
  }
}

Input schema

As the server sends it in tools/list.

{
  "type": "object",
  "properties": {
    "reference": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "const": "upload"
            },
            "upload_id": {
              "type": "string",
              "format": "uuid"
            }
          },
          "required": [
            "type",
            "upload_id"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "type": {
              "type": "string",
              "const": "generation"
            },
            "generation_id": {
              "type": "string",
              "format": "uuid"
            }
          },
          "required": [
            "type",
            "generation_id"
          ],
          "additionalProperties": false
        }
      ]
    },
    "filename": {
      "type": "string",
      "minLength": 1,
      "maxLength": 120
    },
    "as": {
      "type": "string",
      "enum": [
        "url",
        "image"
      ],
      "description": "url (the default) returns the link alone; image also attaches the picture itself as a 1280px WebP."
    }
  },
  "required": [
    "reference"
  ],
  "additionalProperties": false
}

Related tools

Every tool· This page as Markdown