Runware
Generate images and run AI models with Runware's inference API.
On this page
Connect
Auth type: API key (secret_text). Paste the API key (or token) from the provider's settings into the connect dialog. It is encrypted at rest and only decrypted on the server when an action runs.
- In the editor: Backend panel, Integrations tab, then Connect. This connects it for the project.
- For every project in a workspace: Workspace settings, Integrations.
- Owners and admins choose which integrations members may connect in the admin panel (Integrations tab), and can attach their own OAuth app there.
Call it from a workflow
Pass the action name and its input. The call resolves with { success, output, error? }; a missing connection resolves with success false and the reason. See ctx.integrations.invoke and ctx.integrations.call.
// .workflow.js (native ctx)
export async function run(ctx) {
const res = await ctx.integrations.invoke("runware", "generateImagesFromExistingImage", {
"seedImage": "<seed image>",
"model": "<model>",
"positivePrompt": "<positive prompt>",
"height": 1,
"width": 1
});
if (!res.success) throw new Error(res.error);
ctx.log.info("Runware answered", { output: res.output });
}// defineWorkflow module (@app/sdk ctx)
import { defineWorkflow } from "@app/sdk";
export default defineWorkflow({
id: "runware-generateimagesfromexistingimage",
name: "Runware: Generate Images from Existing Image",
description: "Calls Runware when a row is created.",
trigger: { type: "entity_event", entity: "tickets", event: "created" },
async run(ctx, event) {
const res = await ctx.integrations.call("runware", {
"action": "generateImagesFromExistingImage",
"seedImage": "<seed image>",
"model": "<model>",
"positivePrompt": "<positive prompt>",
"height": 1,
"width": 1
}) as { success: boolean; error?: string };
if (!res.success) throw new Error(res.error);
},
});curl -X POST "$APP_ORIGIN/__appbricx/connector-proxy/runware/generateImagesFromExistingImage" \
-H "Authorization: Bearer $APP_KEY" \
-H "content-type: application/json" \
-d '{"props":{"seedImage":"<seed image>","model":"<model>","positivePrompt":"<positive prompt>","height":1,"width":1}}'Actions
generateImagesFromExistingImagein catalog
Generate Images from Existing Image. Generate new images based on a provided image (image-to-image).
| Input | Type | Description |
|---|---|---|
seedImagerequired | text | A URL for the seed image to base the generation on. |
modelrequired | text | You can find model in the Model Explorer (https://my.runware.ai/models/all) tool. |
positivePromptrequired | long text | A positive prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides positive guidance for the task. This parameter is essential t… |
heightrequired | number | Used to define the height dimension of the generated image. Certain models perform better with specific dimensions. |
widthrequired | number | Used to define the width dimension of the generated image. Certain models perform better with specific dimensions. |
negativePromptoptional | long text | A negative prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides negative guidance for the task. This parameter helps to avoid… |
strengthoptional | number | A value between 0 and 1 that indicates how much to transform the seed image. A value of 0 will keep the image as is, while a value of 1 will completely transform it according to the prompt. |
stepsoptional | number | The number of steps is the number of iterations the model will perform to generate the image. The higher the number of steps, the more detailed the image will be. However, increasing the number of st… |
CFGScaleoptional | number | Guidance scale represents how closely the images will resemble the prompt or how much freedom the AI model has. Higher values are closer to the prompt. Low values may reduce the quality of the result… |
scheduleroptional | text | An scheduler is a component that manages the inference process. Different schedulers can be used to achieve different results like more detailed images, faster inference, or more accurate results. |
generateImagesFromTextin catalog
Generate Images from Text. Produce images from a text description.
| Input | Type | Description |
|---|---|---|
modelrequired | text | You can find model in the Model Explorer (https://my.runware.ai/models/all) tool. |
positivePromptrequired | long text | A positive prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides positive guidance for the task. This parameter is essential t… |
negativePromptoptional | long text | A negative prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides negative guidance for the task. This parameter helps to avoid… |
heightrequired | number | Used to define the height dimension of the generated image. Certain models perform better with specific dimensions. |
widthrequired | number | Used to define the width dimension of the generated image. Certain models perform better with specific dimensions. |
stepsoptional | number | The number of steps is the number of iterations the model will perform to generate the image. The higher the number of steps, the more detailed the image will be. However, increasing the number of st… |
CFGScaleoptional | number | Guidance scale represents how closely the images will resemble the prompt or how much freedom the AI model has. Higher values are closer to the prompt. Low values may reduce the quality of the result… |
scheduleroptional | text | An scheduler is a component that manages the inference process. Different schedulers can be used to achieve different results like more detailed images, faster inference, or more accurate results. |
seedoptional | number | A seed is a value used to randomize the image generation. If you want to make images reproducible (generate the same image multiple times), you can use the same seed value. |
vaeoptional | text | VAE (Variational Autoencoder) is a type of neural network architecture used for generating images. Some models may require a specific VAE to work properly. If you want to use a specific VAE, you can … |
clipSkipoptional | number | Defines additional layer skips during prompt processing in the CLIP model. Some models already skip layers by default, this parameter adds extra skips on top of those. Different values affect how you… |
generateVideoFromTextin catalog
Generate Video from Text. Generate video from text prompt.
| Input | Type | Description |
|---|---|---|
positivePromptrequired | long text | A positive prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides positive guidance for the task. This parameter is essential t… |
negativePromptoptional | long text | A negative prompt is a text instruction to guide the model on generating the image. It is usually a sentence or a paragraph that provides negative guidance for the task. This parameter helps to avoid… |
modelrequired | text | You can find model in the Model Explorer (https://my.runware.ai/models/all) tool. |
durationoptional | number | The duration of the generated video in seconds. |
fpsoptional | number | Frames per second for the generated video. |
outputFormatoptional | one of "MP4" | "WEBM" | "MOV" | The format of the generated video. |
outputQualityoptional | number | Sets the compression quality of the output video. Higher values preserve more quality but increase file size, lower values reduce file size but decrease quality. |
uploadEndpointoptional | text | Specifies a URL where the generated content will be automatically uploaded using the HTTP PUT method. The raw binary data of the media file is sent directly as the request body. For secure uploads to… |
numberResultsoptional | number | Specifies how many videos to generate for the given parameters. Each video will have the same parameters but different seeds, resulting in variations of the same concept. |
imageBackgroundRemovalin catalog
Image Background Removal. Request image background removal.
| Input | Type | Description |
|---|---|---|
inputImagerequired | text | A URL for the image to have its background removed. |
modelrequired | text | You can find model in the Model Explorer (https://my.runware.ai/models/all) tool. |
outputFormatoptional | one of "PNG" | "JPG" | "WEBP" | The format of the output image with the background removed. |
outputQualityoptional | number | Sets the compression quality of the output image. Higher values preserve more quality but increase file size, lower values reduce file size but decrease quality. |
uploadEndpointoptional | text | Specifies a URL where the generated content will be automatically uploaded using the HTTP PUT method. The raw binary data of the media file is sent directly as the request body. For secure uploads to… |
Details
- Id
runware- Category
- AI and ML
- Tags
- image, generation, inference, ai
- Package
@activepieces/piece-runware@0.1.3- Tier
- Community