Skip to main content
GET
/
results
/
{jobId}
/
images
/
{filename}
Python SDK
from pulse import Pulse

client = Pulse(api_key="YOUR_API_KEY")

# `get_image` is a streaming generator — join the chunks to
# get the full PNG/JPEG bytes.
chunks = list(client.results.get_image(
    job_id="13e3e75f-a89a-4d33-a391-e1a17127ab38",
    filename="excel_image_1_1.png",
))
png_bytes = b"".join(chunks)

with open("chart.png", "wb") as f:
    f.write(png_bytes)
"<string>"

Overview

Fetch a PNG or JPEG visual image referenced by an extraction response under bounding_boxes.Images[].image_url. When you call /extract with figure_processing.show_images: true, every detected chart or embedded image in the response carries an image_url field. Those URLs point at this endpoint — GET /results/{jobId}/images/{filename} — which streams the actual image bytes.
{
  "bounding_boxes": {
    "Images": [
      {
        "id": "excel_image_1_1",
        "visual_type": "chart",
        "image_url": "https://api.runpulse.com/results/13e3e75f-.../images/excel_image_1_1.png",
        "chart_type": "BarChart",
        "chart_title": "Revenue",
        "excel_range": "D2",
        "sheet_name": "Charts"
      }
    ]
  }
}
This endpoint is most useful for spreadsheet extractions, where charts and embedded images are read directly from the workbook. For PDFs and image inputs, the same shape applies whenever figure detection is enabled.

When to use this vs. /large_results/{jobId}

EndpointPurposeAuthSingle-use?
GET /large_results/{jobId}Download the full extraction result (markdown + bounding_boxes + …) when the inline payload exceeds 5 MB or 70 pages.Anonymous within 1-hour TTL or authenticated same-org.Yes — fetching invalidates the link.
GET /results/{jobId}/images/{filename}Download one visual image referenced by bounding_boxes.Images[].image_url.Authenticated same-org only. No anonymous access.No — fetch as many times as you need while the artifact is retained.
Fetching a visual image does not consume the parent extraction’s result-delivery slot, because a single extraction can contain many image URLs.

End-to-End Example

The full path: extract a workbook → walk the typed Images array → fetch one chart’s bytes.
from pulse import Pulse
from pulse.types import ExtractRequestFigureProcessing

client = Pulse(api_key="YOUR_API_KEY")

# 1) Extract a workbook and ask for image URLs.
response = client.extract(
    file=open("financials.xlsx", "rb"),
    figure_processing=ExtractRequestFigureProcessing(
        show_images=True,
        description=False,
    ),
)

# 2) Walk the typed Images array.
for img in response.bounding_boxes.images or []:
    print(img.id, img.visual_type, img.chart_title, img.image_url)

# 3) Fetch the bytes for the first chart.
import re

img = response.bounding_boxes.images[0]
m = re.search(r"/results/([^/]+)/images/([^/?#]+)", img.image_url)
job_id, filename = m.group(1), m.group(2)

# `get_image` returns an iterator of byte chunks — join to get the full PNG.
chunks = list(client.results.get_image(job_id=job_id, filename=filename))
png_bytes = b"".join(chunks)

with open("chart.png", "wb") as f:
    f.write(png_bytes)

Authentication

Every request must present a valid x-api-key header for the org that owns the extraction. Unlike the legacy single-use /large_results/{jobId} route, visual artifacts are independently-addressable resources — there is no anonymous fallback or short-lived public link.
  • Authenticated same-org calls (your x-api-key matches the org that produced the extraction): succeed for as long as the underlying artifact is retained — same window as any other extraction artifact for that org.
  • Missing credentials (no x-api-key header): rejected with 401 Unauthorized (AUTH_001).
  • Cross-org authenticated calls (valid key, but not the owning org): rejected with 403 Forbidden (AUTH_002).
Use the same key configuration as your other Pulse SDK calls — the SDK’s Pulse(api_key=...) / new PulseClient({ apiKey: ... }) constructor will attach x-api-key to every results.getImage fetch automatically.
Embedding image_url directly in public UIs (e.g. a server-rendered HTML page exposed to unauthenticated visitors) will fail with 401. For public/anonymous embeds, fetch the bytes server-side using your API key and re-host them, or proxy them through your own auth layer.
Repeated fetches against the same image_url are fine — the link is multi-use. Fetching does not consume the parent extraction’s result-delivery slot, so one extraction can produce many image URLs and each can be downloaded as many times as needed.

Errors

StatusCodeMeaning
400 Bad RequestINVALID_REQUESTThe filename path segment failed safe-filename validation.
401 UnauthorizedAUTH_001No x-api-key (or no valid signed-in session) was supplied.
403 ForbiddenAUTH_002The caller is authenticated but does not belong to the org that owns this extraction.
404 Not FoundNOT_FOUNDJob or visual image not found. The jobId or filename is wrong, or the artifact has been garbage-collected.

Next Steps

Bounding Boxes

Full reference for the Images, Tables, Text, Title, and Footer arrays.

Extract Endpoint

Enable figure_processing.show_images to populate image_url.

Authorizations

x-api-key
string
header
required

API key for authentication

Path Parameters

jobId
string
required

Job identifier — same value used in the image_url returned from /extract.

filename
string
required

Visual filename — e.g. excel_image_1_1.png. Must be the exact filename segment from the image_url.

Response

Visual image bytes (image/png or image/jpeg).

The response is of type file.