generate
Run a generative AI model and get the output as a media URL or assistant text. Pay per call with USDC from your wallet.
Instructions
Run a model and return the result — a media URL for image/video/audio/music models, assistant text for text (LLM) models. Text models take OpenAI-style input: { messages: [{ role, content }, …], max_tokens? }. PAID: settles the price from your wallet over the configured rail (base/tempo/solana). Call get_schema first for the input shape, get_price for the cost. File inputs (image/video/audio, e.g. image-to-video or video-to-video video_uri) take a public URL — upload a local file with POST /v1/media (≤40MB) to get one. Array file fields (e.g. images, reference_images for multi-reference models) take an ARRAY of such URLs.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input | Yes | Model input, e.g. { prompt: "a red fox" } or { text: "hello" }. See get_schema. | |
| model | Yes | Model id from list_models. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Media URL of the result, when the model returns media. | |
| rail | Yes | ||
| model | Yes | ||
| output | No | Raw model output. | |
| costUsd | Yes | ||
| costMicroUsd | Yes |