Skip to main content

How do I send images or files to a model, and which options does it support?

Find a model's inputs and allowed options, send files or public links, and check the upload limits, file types and common upload errors.

Each model has its own inputs, and the values it offers (ratios, durations, output formats, number of files) are fixed for that model. Here's how to find them and send files or links.

Find a model's inputs and options

  • Model page: each field lists its allowed values, with more under Show advanced configurations. The API Integration Guide tab has ready-made code.

  • API: Tool/Detail (see your first API request) returns tool[0].parameters, which lists the inputs in groups. In each group's items, id is the input name, type its type, defaultvalue its default and, for a select, options its allowed values. See Discovering Parameters.

If an option is missing

  • An unlisted value, such as 21:9 or a longer video, isn't supported by that model; it's not a bug. The API answers Request parameter [ratio] must be one of: ... or, for numbers, Request parameter [...] must be between ... and ...

  • Another model or variant may have it. openai/gpt-image-2 has no 21:9, but openai/gpt-image-2-custom takes Width and Height, and google/nano-banana offers 21:9.

  • Omit an optional setting in an API request and Wiro uses its defaultvalue.

  • The output file type is selectable only through a model setting, such as Output Format on openai/gpt-image-2; otherwise, convert images with wiro/image-converter.

File input types

As named in Parameter Types:

  • fileinput: Single file upload (1 file).

  • multifileinput: Multiple files (up to N files). Repeat the field once per file.

  • combinefileinput: Up to N entries (files, URLs, or mixed). Repeat the same field for each file or link, with no Url suffix.

Send files as multipart/form-data. With links only, JSON also works, using an array for a combinefileinput. The help text usually gives N, and more returns, for example, Request parameters [inputImage] not valid.

Using a link instead of a file

  • It must be public and point at the file itself: a private browser window opens or downloads it without sign-in. Share and preview pages don't work.

  • In the API, a fileinput or multifileinput takes a link only in a separate URL input, if the model has one (such as inputImageUrl). A required file input still needs the file (otherwise request-files-required).

  • In a combinefileinput for images, video, audio or documents, each link's file type is checked first. A wrong type or unreachable link returns Uploaded file format invalid. Supported: ... If a link that opens fine is rejected, upload the file.

  • Other links are fetched only by the model. If it can't, the task fails; its Debug output may show, for example, [Image 1] is missing or could not be downloaded.

Upload limits and file types

  • Size: 100 MB per file, for File/Upload and model inputs. Larger files get HTTP 413 and the plain-text message File size limit has been reached.

  • Types: our docs list images (jpg, png, gif, jpeg, webp, heic), video (mp4, webm, mov), audio (mp3, wav, m4a) and documents (pdf, csv, docx, xlsx, pptx, txt, md, epub). Image inputs take images, video inputs video, and so on.

  • ZIP: File/Upload unpacks it into a new folder, keeping only top-level files. With curl, send it as [email protected];type=application/zip. See POST /File/Upload.

Example: send a file with the API

This runs wiro/image-converter, whose inputImage is a combinefileinput:

curl -X POST "https://api.wiro.ai/v1/Run/wiro/image-converter" \
-H "x-api-key: YOUR_API_KEY" \
-F "inputImage=@/path/to/photo.jpg" \
-F "outputFormat=png"

For a link, use -F "inputImage=https://example.com/photo.jpg". Don't set Content-Type; curl does. This works with an API Key Only project; a Signature Based project also sends x-nonce and x-signature (see Authentication). More: File Upload Patterns.

If an upload doesn't work

  1. Check size, type and count. Many upload boxes list types after Supports: and show File type not allowed: ... or Maximum ... files allowed.

  2. Test a link in a private window. On a model page, a public link can still fail with Could not prepare remote file for ... if its site blocks outside downloads, and a blob: link gives Blob URLs are not supported. Please use a direct file URL. Either way, upload the file.

  3. If the run started but failed, see why a task failed or has no output. Other API errors: What does my API error mean?

Input errors come back before a task exists, so they cost nothing. For what a run costs and when it's charged, see How is a model priced?

Did this answer your question?