View as Markdown
DreamStudio (Stable Diffusion) icon

DreamStudio (Stable Diffusion) ACTION

Modify Image

Modify an image based on a text prompt. See the documentation
  • Action
  • Read only
  • API key
  • SDK
  • MCP

IMPLEMENTATION

Call this tool

Connect a user's DreamStudio (Stable Diffusion) account once, then configure and run Modify Image from your backend or agent.

import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "dreamstudio-modify-image",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    dreamstudio: { authProvisionId: "apn_xxxxxxx" },
    organizationId: "Organization Id",
    engineId: "Engine Id",
  },
})

console.log(result)

SCHEMA

Inputs

Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.

Modify Image inputs
Property Type Description
organizationId Organization Id string
The id of the organization.
Required Dynamic
engineId Engine Id string
The id of the engine.
Required Dynamic
textPrompts Text Prompts string[]
An array of valid JSON objects to use for generation. The JSON object must have the text and the weight. e.g.{"text": "A lighthouse on a cliff", "weight": 0.5}
Required
initImage Init Image Path Or Url string
Provide either a file URL or a path to a file in the /tmp directory (for example, /tmp/example.png)
Required
cfgScale Cfg Scale integer
How strictly the diffusion process adheres to the prompt text (higher values keep your image closer to your prompt).
Optional
clipGuidancePreset Clip Guidance Preset string
Clip Guidance Preset
Optional
sampler Sampler string
Which sampler to use for the diffusion process. If this value is omitted we'll automatically select an appropriate sampler for you.
Optional
samples Samples integer
Number of images to generate
Optional
seed Seed integer
Random noise seed (omit this option or use 0 for a random seed).
Optional
steps Steps integer
Number od diffusion steps to run.
Optional
stylePreset Style Preset string
Pass in a style preset to guide the image model towards a particular style.
Optional
extras Extras object
Extra parameters passed to the engine. These parameters are used for in-development or experimental features and may charge without werning, so please use with caution.
Optional
initImageMode Init Image Mode string
Used to control how much influence the init image has on the result.
Optional
syncDir SyncDir dir
Required

REFERENCE

Tool details

Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.

Registry key
dreamstudio-modify-image
Version
1.0.3
App
DreamStudio (Stable Diffusion)
Authentication
API key
Read-only
Yes
Destructive
No
Open world
Yes