Bria Reimagine API

Bria AI Reimagine transforms reference images into detailed, styled visuals with creative flexibility.

PlaygroundAPIPricing
~13.28s
POST /v2/bria-reimagine · submit + poll
 1# pip install "segmind>=1.1.0"
 2# export SEGMIND_API_KEY="YOUR_API_KEY"
 3import segmind
 4
 5# Async (v2): submit to the queue and block until COMPLETED.
 6# run() returns the final result dict (600s deadline, 1.0s poll by default).
 7result = segmind.run(
 8    "bria-reimagine",
 9    structure_image_url="https://segmind-resources.s3.amazonaws.com/input/a2fd894f-6e14-4a8c-9125-124a5dddddcd-dd2c8055-316b-4bab-8d2b-00738cd94a67.png",
10    prompt="A vibrant autumn-themed coffee shop interior, with orange and red leaves visible through the windows, cozy lighting enhanced with golden hues, and the pastries decorated for fall, maintaining the original layout and perspective from the reference image",
11    fast=True,
12    seed=42,
13    enhance_image=False,
14    prompt_content_moderation=True,
15    content_moderation=False,
16    ip_signal=False,
17    include_generation_prefix=True,
18    steps_num=12,
19)
20print(result["status"])                      # COMPLETED
21print(result.get("output"))                  # model output (e.g. media URL)
22print(result["metrics"]["inference_time"])   # server compute seconds
23
24# --- Or submit + poll manually (track request_id, control the cadence) ---
25from segmind import SegmindClient, InferenceFailed, InferenceTimeout
26
27client = SegmindClient()                      # reads SEGMIND_API_KEY
28payload = {
29    "structure_image_url": "https://segmind-resources.s3.amazonaws.com/input/a2fd894f-6e14-4a8c-9125-124a5dddddcd-dd2c8055-316b-4bab-8d2b-00738cd94a67.png",
30    "prompt": "A vibrant autumn-themed coffee shop interior, with orange and red leaves visible through the windows, cozy lighting enhanced with golden hues, and the pastries decorated for fall, maintaining the original layout and perspective from the reference image",
31    "fast": True,
32    "seed": 42,
33    "enhance_image": False,
34    "prompt_content_moderation": True,
35    "content_moderation": False,
36    "ip_signal": False,
37    "include_generation_prefix": True,
38    "steps_num": 12,
39}
40job = client.submit_async("bria-reimagine", **payload)
41print(job.request_id)                         # available immediately
42try:
43    result = job.wait(timeout=600, interval=1.0)
44except InferenceTimeout as e:
45    print("still running:", e.request_id)
46except InferenceFailed as e:
47    print("failed:", e.detail)

API Endpoint

POSThttps://api.segmind.com/v1/bria-reimagine

Parameters

promptrequired
string

Input text for desired image. Descriptive prompts yield detailed outputs.

Default: "A vibrant autumn-themed coffee shop interior, with orange and red leaves visible through the windows, cozy lighting enhanced with golden hues, and the pastries decorated for fall, maintaining the original layout and perspective from the reference image"
content_moderationoptional
boolean

Enforces image content guidelines. Disable for unrestricted creation.

Default: false
enhance_imageoptional
boolean

Enhances image details. Enable for high-quality outputs.

Default: false
fastoptional
boolean

Enables speed over detail. Use for quick results.

Default: true
include_generation_prefixoptional
boolean

Adds model generation prefix. Enable for consistency with standards.

Default: true
ip_signaloptional
boolean

Detects potential IP issues. Useful in professional settings.

Default: false
prompt_content_moderationoptional
boolean

Moderates prompt content for safety. Disable for unmoderated input.

Default: true
seedoptional
integer

Sets image seed for reproducibility. Useful for recreating identical images.

Default: 42
steps_numoptional
integer

Sets refinement iterations. Higher values increase detail.

Default: 12Range: 4 - 50
structure_image_urloptional
string (uri)

Provides a URL for a reference image. Use detailed images for complex compositions.

Default: "https://segmind-resources.s3.amazonaws.com/input/a2fd894f-6e14-4a8c-9125-124a5dddddcd-dd2c8055-316b-4bab-8d2b-00738cd94a67.png"
structure_ref_influenceoptional
float

Sets influence of reference image. Increase for precise adherence.

Default: 0.75Range: 0 - 1

Response Type

Returns: Image

Asynchronous requests (v2)

Use Async for video, long-running (>~60s), or high-concurrency workloads; Sync is simplest for fast image & LLM calls. Async submits a request and you poll it to completion.

  1. 1
    POST /v2/bria-reimagine

    Submit — returns request_id, status_url, response_url

  2. 2
    GET /v2/requests/{id}/status

    Poll — until COMPLETED or FAILED

  3. 3
    GET /v2/requests/{id}

    Result — final response body

Status states

QUEUED— Accepted, waiting for a worker
PROCESSING— Running on a worker
COMPLETED— Done — result body is ready
FAILED— Errored (incl. content/RAI blocks)
  • A FAILED request is served as HTTP 422 — the body still carries the error detail.
  • An unknown or expired request_id returns HTTP 404.
  • Results are retained for 1 hour, then expire.
  • Content / RAI blocks surface as FAILED, not a separate state.
  • Track completion by polling the status endpoint.

Common Error Codes

The API returns standard HTTP status codes. Detailed error messages are provided in the response body.

400

Bad Request

Invalid parameters or request format

401

Unauthorized

Missing or invalid API key

403

Forbidden

Insufficient permissions

404

Not Found

Model or endpoint not found

406

Insufficient Credits

Not enough credits to process request

429

Rate Limited

Too many requests

500

Server Error

Internal server error

502

Bad Gateway

Service temporarily unavailable

504

Timeout

Request timed out