ai

POST /v1/ai/images/credentials/{credentialId}/test

Check an image key now, by generating a real image with it.

Todos los endpoints de ai

Autenticación

Envía una clave de API como token de portador. La clave debe tener el permiso billing.manage; una clave que no lo tenga se rechazará con un código 403, no 404.

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 POST https://api.zinndigital.com/v1/ai/images/credentials/{credentialId}/test \
  -H "Authorization: Bearer zdk_live_…"

¿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

The customer's own "check it now". Same mechanism as the scheduled sweep, so the answer on screen and the answer in the sweep can never disagree. ⛔ A `POST` and not a `GET` because it **costs money**: it draws an image on the customer's provider account. A GET that spends would be retried by every browser, proxy and prefetcher on the path. Requires `billing.manage`.

Parámetros

NombreTipoObligatorio¿Qué es esto?
credentialId (path)Uuid

Respuesta

NombreTipoObligatorio¿Qué es esto?
idUuidUUIDv7 identifier — sortable by creation time (docs/02 §8).
providerAiImageProviderAn image-generation provider. ⛔ Deliberately a different enum from the text `provider` on `AiCredential`: Anthropic publishes no image model and xAI publishes no text model we u…
labelstring
verified_atobjectNoThe last time a **real image generation** on this key succeeded. ⛔ `null` means never proven, not broken. Moved only by a generation, never by a cheap auth probe: a probe proves…
last_checked_atobjectNoThe last time any check ran, pass or fail. Separate from `verified_at` so *"we have not looked recently"* is distinguishable from *"we looked and it failed"*.
last_check_okobjectNo
last_check_errorstringNoThe provider's own words when the last check failed. Empty otherwise.
broken_sinceobjectNoWhen the key first failed after last passing, or `null` if it is not currently broken. ⭐ This is what makes "notify on transition to broken, never per check" possible — a key br…
last_used_atobjectNo
created_atstring

Errores que este endpoint puede devolver

401 · 403 · 404 · 429