marketplace

PATCH /v1/marketplace/listings/{listing_id}/images/{image_id}

Set the alt text, the gallery position, or make this the cover.

Todos los endpoints de marketplace

Autenticación

Envía una clave de API como token de portador. Este endpoint no especifica un permiso concreto en la especificación, así que otorga a tu clave los mínimos privilegios necesarios y comprueba la respuesta en lugar de dar por sentado.

Este endpoint no requiere ningún id de organización. Su clave ya identifica la organización a la que pertenece, y la respuesta está delimitada a ella.

Pruébalo

Reemplaza cualquier elemento entre corchetes angulares por tus propios valores, y el marcador de posición key con una clave de tu panel de control.

curl -X PATCH https://api.zinndigital.com/v1/marketplace/listings/{listing_id}/images/{image_id} \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{  }'

¿Has iniciado sesión? La consola de la API en tu panel de control rellena el ID de tu organización real y tu propia clave, y ejecuta la solicitud contra la API en vivo para que puedas ver la respuesta real. Abre este endpoint en la consola de la API

Detalles

Promoting a cover demotes the incumbent in the same write — there is a partial unique constraint allowing exactly one cover per listing, so doing it in two steps would fail.

Parámetros

NombreTipoObligatorio¿Qué es esto?
listing_id (path)string
image_id (path)string

Cuerpo de la solicitud

NombreTipoObligatorio¿Qué es esto?
altstringNo
positionintegerNo
is_coverbooleanNoOnly `true` is meaningful — a listing always has exactly one cover.

Respuesta

NombreTipoObligatorio¿Qué es esto?
idstring
urlstringNoThe original. ⛔ `null` when no public delivery origin is configured, rather than a guessed URL — an R2 bucket is not public by default, and a card with a broken image is worse t…
srcsetstringNoWidth candidates through Cloudflare image resizing with `format=auto`, so a phone downloads a phone-sized AVIF/WebP and an old browser still gets something it can decode. Empty…
widthintegerPixel width AFTER orientation is applied. Required in the markup to reserve space — an `<img>` without it is the largest single source of layout shift.
heightintegerPixel height after orientation is applied.
altstringNo
is_coverboolean
positioninteger

Errores que este endpoint puede devolver

401 · 404