Custom Templates

Effortlessly tailor custom scenes to match your branding, themes, and products. Perfect for creating unique brand touchpoints and compelling marketing images. Try it out here first, then get in touch to learn how we can bring your business images to the next level.

CNY-SnakeYear
CNY-SnakeYear

This workflow contains Moondream + AutoGen + Flux Snake Year scene Each endpoint output one generation but two outputs, with frame or without.

This document provides an example of how to post a job for a specific endpoint and then query its status until it is completed.

Step 1: Post a Job

To submit a job, use the POST method with the necessary parameters for the endpoint. Below is an example:

curl -X POST -H "Authorization: Bearer YOUR_API_KEY" \
    -F "data[#22][load_image]=@/path/to/file" \
    -F "data[flux-sampler-parameters-seed#56][seed]=20" \
    "https://toolkit.instantstudio.ai/api/v1/jobs?endpoint=PrOhEE"

Sample Response:

{
  "job_id": "44fefe50-2547-494f-aaa2-71dc3f661234",
  "job_state": "pending",
  "started_at": null,
  "completed_at": null
}

Step 2: Query the Job Status

Once the job is submitted, use the GET method to query its status using the job_id from the response.

curl -X GET -H "Authorization: Bearer <api_key>" \
    "https://toolkit.instantstudio.ai/api/v1/jobs/44fefe50-2547-494f-aaa2-71dc3f661234"

Sample Responses:

  • In Queue:
{
  "job_id": "44fefe50-2547-494f-aaa2-71dc3f661234",
  "job_state": "in_queue",
  "started_at": null,
  "completed_at": null
}
  • Processing:
{
  "job_id": "44fefe50-2547-494f-aaa2-71dc3f661234",
  "job_state": "processing",
  "started_at": "2024-12-11T13:47:30.421+08:00",
  "completed_at": null
}
  • Succeeded:
{
  "job_id": "44fefe50-2547-494f-aaa2-71dc3f661234",
  "job_state": "succeeded",
  "started_at": "2024-12-11T13:47:30.421+08:00",
  "completed_at": "2024-12-11T13:51:00.829+08:00",
  "image_urls": [
    "..."
  ]
}

Notes:

  • Continue polling the GET endpoint until the job_state is "succeeded" or "failed".
  • Ensure to save the generated images (image_urls) before the job data is deleted after 24 hours.

Generated Images