ai
POST /v1/ai/site-builds/{siteBuildId}/images
Draw the draft's images. Charges the content-images meter.
Authentification
Envoyez une clé API en tant que jeton du porteur. La clé doit posséder l'autorisation sites.create ; une clé qui ne l'a pas est refusée avec le code 403, et non 404.
Cet endpoint ne prend aucun identifiant d'organisation. Votre clé identifie déjà l'organisation à laquelle elle appartient, et la réponse y est limitée.
Essayer
Remplacez tout ce qui se trouve entre crochets par vos propres valeurs, et le espace réservé à la clé par une clé de votre tableau de bord.
curl -X POST https://api.zinndigital.com/v1/ai/site-builds/{siteBuildId}/images \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "agreed_total_usd_micros": <integer> }'Connecté ? La console d'API de votre tableau de bord saisit votre véritable ID d'organisation ainsi que votre propre clé, et exécute la requête sur l'API de production afin que vous puissiez voir la réponse réelle. Ouvrir ce point de terminaison dans la console API
Détails
Generates every image the markup asks for and stores it against the draft, so a publish carries the pictures as well as the markup. **Send back the total you were quoted.** If the price has moved since — the catalogue changed, a model was withdrawn, another tab generated some of the same images — this is refused with `price_moved` and nothing is charged. A confirm that charged a different number from the one on the screen is the one thing a money confirm must never do. Images already generated are skipped and not re-charged, so pressing the button twice costs nothing the second time. Two meters bill for a draft with images: the build's own generation, and this. Both are visible on the organization's AI usage screen. Requires `sites.create`.
Paramètres
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
siteBuildId (path) | Uuid | Oui | — |
Corps de la requête
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
agreed_total_usd_micros | integer | Oui | The `total_usd_micros` you were quoted. Refused with `price_moved` if it no longer matches, and nothing is charged. |
provider | string | Non | — |
model | string | Non | — |
Réponse
| Nom | Type | Obligatoire | Qu'est-ce que c'est |
|---|---|---|---|
images | SiteBuildImage[] | Oui | — |
build | SiteBuild | Oui | One "describe a site and we build it" run. `files` is present on the **detail** and create responses and absent from the **list**, deliberately: a generated tree can be a hundre… |
Erreurs que cet point de terminaison peut renvoyer
401 · 403 · 404 · 422 · 429