Skip to content

execute_forge

Execute a forge run to generate images, videos, 3D models, or audio.

Pass a `base_model_id`, at least one entry in `reference_sets`, or both. With reference sets
and no base model, a compatible model is picked automatically from the sets.

Returns immediately with an inference ID, which can be polled with `get_forge_run` for results.

Call `get_forge_instructions` first for full forge lifecycle guidance.

Parameters

ParameterTypeDefaultDescription
base_model_idstringBase model to run, given as an id (e.g. flux-dev), display name, or community alias (e.g. 'Nano Banana 2'). Not required when passing reference sets — a compatible model is then auto-picked from them. Required otherwise. Find ids with `list_base_models`.
reference_setsForgeReferenceSetInput[][]Reference Sets to translate into guidance inputs and prompt text for the target model. Required when no base_model_id is given — the model is then auto-picked from the sets. Find ids with `list_reference_sets`.
set_idrequiredstring (uuid)Reference Set ID, from `list_reference_sets`.
weightnumber0–21Weight for the set's LoRA adapter when one applies. 1.0 = as trained; lower weakens, higher over-applies. Ignored for sets applied as reference images or prompt text.
modalityenumOutput modality: image, video, three_d, or audio. Used to disambiguate reference-set translation; inferred from the reference sets when omitted. Not required with a base_model_id.
One of: text, image, audio, video, three_d, playable
promptstringText prompt describing what to generate.
widthinteger>0Output width in pixels. Pass both width and height whenever the output must have a specific aspect ratio: with either one absent and an init image, editing reference, or first frame attached, the output geometry is taken from that file rather than from a model default.
heightinteger>0Output height in pixels. Pass both width and height whenever the output must have a specific aspect ratio: with either one absent and an init image, editing reference, or first frame attached, the output geometry is taken from that file rather than from a model default.
batch_sizeinteger1–164Number of outputs to generate (1-16).
seedinteger-1Random seed. -1 for random.
guidance_filesForgeGuidanceFileInput[][]Reference images/files to guide generation.
file_idrequiredstring (uuid)File ID of an uploaded file.
typerequiredstringGuidance type: init_image, reference_image, pose, depth, canny, softedge_hed, segmentation, lineart, face, first_frame, last_frame, init_video, reference_video, reference_audio, init_audio, init_mesh, texture_image, scribble, color_sketch. See model capabilities for supported types per model.
weightnumber0–1Influence weight (0-1). Defaults to 0.5 for init_image, 1 for others.
maskForgeMaskInputMask for inpainting/outpainting. Provide file_id or transparency flags.
file_idstring (uuid)Mask image file ID.
for_transparencybooleanUse transparent areas as mask.
for_nontransparencybooleanUse non-transparent areas as mask.
edge_radiusinteger≥00Mask edge blur radius in pixels.
cameraForgeCameraInputCamera view change relative to the input image: orbit to a side/back/top view, or zoom. Requires the source image attached as an init_image or reference_image guidance file supported by the model, and only models whose capabilities report camera_transform accept it (check get_model / get_base_model). Supply view direction here; dispatch encodes it in the model's required format.
yaw_degreesnumber-360–360Orbit horizontally around the subject, in degrees: 90 = right side view, 180 = back view, 270 (or -90) = left side view.
pitch_degreesnumber-30–90Camera elevation in degrees: positive looks down (90 = top-down), negative looks up (-30 is the lowest supported angle).
roll_degreesnumberBank around the viewing axis in degrees, clockwise positive. Natively camera-capable models ignore roll.
distance_deltanumberDolly out (positive) / in (negative), in scene units; ~5 spans wide shot to close-up.
fov_delta_degreesnumberField-of-view change in degrees: positive widens (zoom out), negative narrows. Alternative to distance_delta.
num_inference_stepsintegerNumber of diffusion steps.
guidance_scalenumberGuidance scale (CFG).
prompt_strengthnumber0–1How closely the generated audio follows the text prompt (0-1); higher means less variation. Honored by ElevenLabs Sound Effects and the Sonilo video-to-music models, and ignored by every other model. To control how closely an image or video generation follows an input image, set guidance_files[].weight instead.
qualityenumQuality level.
One of: low, medium, high
sharpnessnumberOutput sharpness.
duration_secondsnumberOutput length in seconds — video clip length, or audio clip length for models whose duration_seconds_min / duration_seconds_max say they take one.
generate_audiobooleanGenerate audio with video.
keep_audiobooleanKeep audio from input video.
fpsintegerFPS for LTX video generation (e.g. 25 or 50).
video_effectsForgeVideoEffectInput[][]Video effects to apply.
typerequiredstringVideo effect type (UPPERCASE). Common types: GENERAL, ORBIT_360, DOLLY_IN, DOLLY_OUT, ZOOM_IN, ZOOM_OUT, CRANE_UP, CRANE_DOWN, TILT_UP, TILT_DOWN, STATIC, FPV_DRONE, HYPERLAPSE, HANDHELD. See model capabilities for supported effects per model.
weightnumber0–100Effect strength (0-100).
frame_extraction_locationenumWhich frame to extract from an input video: first, middle, or last. Used by ffmpeg-extract-frame and similar models.
One of: first, last, middle, timestamp
use_ta_posebooleanDeprecated: use pose_mode. Legacy rig-ready-pose toggle for 3D.
pose_modeenumRest pose for a character mesh: A_POSE or T_POSE. Support varies by model.
One of: A_POSE, T_POSE
include_texturesbooleanInclude textures in 3D output.
quad_meshbooleanGenerate quad mesh.
pbr_materialsbooleanGenerate PBR materials.
low_polybooleanGenerate low-poly mesh.
generate_partsbooleanGenerate separate parts.
detailed_geometrybooleanGenerate denser, more detailed geometry. Costs extra and only some 3D models support it.
export_uvbooleanSet false to omit UV coordinates from the 3D output.
compress_geometrybooleanReturn a geometry-compressed mesh. Only some 3D models support it.
face_limitintegerFace/polygon limit for 3D mesh.
stabilitynumber0–1Voice stability (0-1).
similarity_boostnumber0–1Voice similarity boost (0-1).
style_exaggerationnumber0–1Style exaggeration (0-1).
speednumberSpeech speed multiplier (ElevenLabs: 0.7-1.2).
text_normalizationenumHow TTS reads out numbers/dates: AUTO, ON, or OFF.
One of: AUTO, ON, OFF
temperaturenumberTTS sampling temperature (Qwen 0-1, Gemini 0-2).
style_instructionsstringFree-text delivery guidance for TTS, distinct from the spoken text (e.g. "excited sports commentator"). Qwen and Gemini TTS models only.
upscale_rationumberUpscale factor (e.g. 2.0, 4.0).
creativitynumberCreative variation strength for upscaling.
resemblancenumberResemblance to original for upscaling.
vectorizebooleanVectorize the output image.
vectorization_modeenumSVG path mode: 'spline' (curved) or 'polygon' (straight lines).
One of: spline, polygon
vectorization_color_modeenumSVG color output: 'color' or 'binary' (black and white).
One of: color, binary
vectorization_filter_speckleinteger0–128Filter out small speckles and noise when vectorizing (0-128).
vectorization_color_precisioninteger1–8Color quantization level when vectorizing (1-8).
remove_backgroundbooleanRemove the background. Effective as the standalone operation on a background-removal model; a generation model does not chain removal onto its outputs on this surface.
reframebooleanReframe/extend the image.
refillbooleanOutpaint/refill transparent areas.
workspace_idrequiredstring (uuid)The user's workspace id.
session_idstring (uuid)The Session ID to attach the results to.
session_namestringCreates a new session with this name. One of `session_name` or `session_id` must specified, but not both.