---
title: "Get an image preview"
method: GET
path: "/v1/bookmarks/{bookmarkId}/media"
tags: ["Bookmarks"]
---

# Get an image preview

`GET /v1/bookmarks/{bookmarkId}/media`

## Request

- Base URL: `https://stashr.me`
- URL: `https://stashr.me/v1/bookmarks/{bookmarkId}/media`
- Auth: HTTP bearer

Return an ownership-scoped JPEG preview (at most 768px on the long edge) of one stored bookmark image, so an agent can look at a picture without pulling full-size media. ref comes from the bookmark's media[].ref. Remote-only images and videos return 404.

## Path parameters

- `bookmarkId` string, uuid, required

## Query parameters

- `ref` string, required

## Response `200`

Bounded image preview; X-Stashr-Media-Ref, X-Stashr-Media-Width, and X-Stashr-Media-Height headers describe it

## Other responses

- `400`: Malformed request (error.code bad_request or invalid_json)
- `401`: Missing, invalid, or expired credentials (error.code unauthorized)
- `402`: A Pro plan or active trial is required (error.code payment_required)
- `403`: The credential lacks the required scope (error.code forbidden)
- `404`: The resource does not exist or belongs to another account (error.code not_found)
- `422`: Validation failed; error.details.issues lists the fields (error.code validation_error)
- `429`: Too many requests (error.code rate_limited); wait Retry-After seconds, also given as error.retryAfterMs
- `500`: Something failed on Stashr's side (error.code internal_error); retryable

---

[API](https://skmtc.dev/stashr/apis/stashr-api.md) · [All operations](https://skmtc.dev/stashr/apis/stashr-api/llms.txt) · [OpenAPI document](https://skmtc.dev/stashr/apis/stashr-api/revisions/bcab186e0646?raw)
