Skip to main content
A wooden fingerpost among gum trees pointing several ways beside a trail map, in a three-ink risograph print

Generating images

How to generate images for your prototypes --- placeholders first, then a third-party text-to-image API

A prototype usually needs one of these: a hero image, an icon set, a texture or a game sprite. Try a placeholder before using an image model or API.

Placeholders first

Most of the time you do not need a real model at all. A prototype is about the build, not the art, so try picsum.photos for stock photos, DiceBear for avatars, or an inline SVG the agent writes for you. These need no key and no billing, and they keep a static site static. Swap in real imagery only once the idea is proven.

When you need a real model

The course key no longer generates images: the course’s image credit has run out. Use a third-party host instead. Two things matter: that you can call it from code, and that the free tier is enough to prototype on.

Good places to look, roughly cheapest first:

Whichever you pick, the process is the same. Sign up, mint an API token, and keep it out of your source: an untracked environment variable, never a committed file (the LLM access page covers the habit). A third-party key is yours rather than the course’s, so its spend is yours too. Stay on free tiers while you prototype, and check the per-image price before you loop over a hundred prompts.

Then call the endpoint from a small script or a build step. If the model only runs server-side, remember the static half has no server: generate the image at build time and commit the output, or leave the live call for the full-stack half.