Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

Bulk-generate images from a list of prompts with one API call (FLUX, no API key)

说明与用途

该方案通过一次 API 调用批量生成图像,消除了逐图像处理的繁琐步骤。

问题

Generating hundreds of images from a list of prompts in a pipeline is cumbersome when each prompt requires a separate API call, key management, and bookkeeping.

结果

The recipe enables bulk image generation with a single API call, eliminating per-image key management, retry logic, and manual storage, while returning a structured dataset with URLs and status for each image.

工作流

  • 1. Create a free Apify account and copy the API token from Settings → Integrations.
  • 2. Prepare a JSON input with fields such as prompts, imageSize, quality, imagesPerPrompt, seed, maxPrompts.
  • 3. Call the Actor via curl, Python, or JavaScript to run the batch generation synchronously.
  • 4. Retrieve the dataset items directly from the API response or via the Apify client.
  • 5. Process each item: if status is "ok" use outputUrl; otherwise handle error.

证据

The pattern that removes all of this: one call that takes the whole list, runs the model, stores the files, and returns one record per image with its URL.

来源

Create a free Apify account and copy your API token from Settings → Integrations.

来源

curl -s -X POST \
"https://api.apify.com/v2/actors/sherwood~image-generator-batch/run-sync-get-dataset-items?token=$APIFY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"prompts": ["A ceramic coffee mug on a wooden table, product photography"]}'

来源

  • 记录日期: 2026-10-19T18:56:25.962Z