get_image
Downloads a Nettskjema image to disk by image ID, writing either to a specified output path or a temporary file and returning the absolute path.
Instructions
Download an image to a file, written to disk.
The image is streamed to disk and never inlined. The returned path is absolute and tilde-expanded. An existing file at the output path is silently overwritten, and its mode is preserved. A new file (whether from output_path or a temp file) is created with mode 0600 (readable only by the current user).
When output_path is omitted, a temporary file is created in the system temp directory with a suffix derived from the response's media type. The temporary file persists after this call returns and is left on disk for the caller to use or delete.
The spec declares the response as / (any media type), so the actual content type is reported as received.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| image_id | Yes | The image's ID (a string, often but not always a UUID). | |
| output_path | No | Destination file path. When omitted, a temporary file is created in the system temp directory. The path may contain ~ for the home directory and may be relative (it will be resolved to an absolute path). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |