PhotoRoom
photoroomPhotoRoom provides AI-powered APIs for removing backgrounds, editing and resizing product photos, generating images from prompts, and checking account credit usage.
Acciones disponibles (4)
Cada acción es una operación que el agente puede ejecutar contra este conector. Haz clic en una acción para ver sus parámetros.
Edit ImagePHOTOROOM_EDIT_IMAGEAcciónApply one or more combined PhotoRoom v2 edits to an image URL or uploaded file; sandbox output is watermarked, while live calls consume plan credits.
PHOTOROOM_EDIT_IMAGEAcciónApply one or more combined PhotoRoom v2 edits to an image URL or uploaded file; sandbox output is watermarked, while live calls consume plan credits.
Parámetros de entrada
marginanyUniform outer margin: a ratio from 0 to 0.49, a percentage from 0% to 49% such as 30%, or a pixel value such as 100px.
paddinganyUniform padding around the subject: a ratio from 0 to 0.49, a percentage from 0% to 49% such as 30%, or a pixel value such as 100px.
image_urlstringuriPublicly reachable direct image URL. Provide exactly one of image_url or image_file.
export_dpinumberOptional output pixel density from 72 to 1200 DPI.
image_fileobjectImage file to upload. Provide exactly one of image_file or image_url.
edit_promptstringDescribe an AI edit to apply through PhotoRoom's editWithAI operation.
environmentstringObligatorioenumChoose live for non-watermarked output that consumes plan credits, or sandbox for free watermarked output.
sandboxliveoutput_sizestringOutput size: WIDTHxHEIGHT such as 128x128, auto, originalImage, or croppedSubject.
shadow_modestringenumShadow generation mode to apply; omit to leave shadows unchanged.
ai.softai.hardai.floatingai.preset-softai.preset-hardai.auto-with-overridestemplate_idstringuuidPhotoRoom template UUID to apply as part of the v2 edit.
upscale_modestringenumUse ai.fast for speed or ai.slow for higher quality; omit to skip upscaling.
ai.fastai.slowexport_formatstringenumOutput image format.
pngjpegjpgwebpavifbackground_colorstringReplace the background with a color name such as red or blue, or a hex value without # such as FF0000 or FF0000EE. Pass remove_background explicitly as false to instead only fill padding and transparent areas with this color.
background_promptstringGenerate a replacement background from this text prompt.
remove_backgroundbooleanRemove the source image background as part of this edit. Setting any background replacement field implies this, since PhotoRoom only replaces a background it has removed.
text_removal_modestringenumRemove artificial text, natural text, or all text; omit to keep detected text.
ai.artificialai.naturalai.allbackground_image_urlstringuriReplace the background with an image from this public URL.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Generate ImagePHOTOROOM_GENERATE_IMAGEAcciónGenerate a new image from a text prompt with PhotoRoom v2; sandbox output is watermarked, while live calls consume plan credits.
PHOTOROOM_GENERATE_IMAGEAcciónGenerate a new image from a text prompt with PhotoRoom v2; sandbox output is watermarked, while live calls consume plan credits.
Parámetros de entrada
seedintegerOptional generation seed for reproducible output when supported.
sizestringenumRequested generated-image size.
LANDSCAPE_16_9LANDSCAPE_4_3PORTRAIT_16_9PORTRAIT_4_3SQUARE_HDpromptstringObligatorioText description of the image to generate.
environmentstringObligatorioenumChoose live for non-watermarked output that consumes plan credits, or sandbox for free watermarked output.
sandboxliveexport_formatstringenumOutput image format.
pngjpegjpgwebpavifremove_backgroundbooleanRemove the generated image background. Defaults to false so the scene described by the prompt is retained.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get Account UsagePHOTOROOM_GET_ACCOUNT_USAGEAcciónReturn the connected live PhotoRoom account's reported plan and remaining image credits.
PHOTOROOM_GET_ACCOUNT_USAGEAcciónReturn the connected live PhotoRoom account's reported plan and remaining image credits.
Parámetros de entrada
Sin parámetros.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Remove BackgroundPHOTOROOM_REMOVE_BACKGROUNDAcciónRemove the background from one uploaded image with PhotoRoom's dedicated Basic API; sandbox output is watermarked, while live calls consume plan credits.
PHOTOROOM_REMOVE_BACKGROUNDAcciónRemove the background from one uploaded image with PhotoRoom's dedicated Basic API; sandbox output is watermarked, while live calls consume plan credits.
Parámetros de entrada
cropbooleanCrop the result around the detected foreground subject.
sizestringenumOutput resolution tier.
previewmediumhdfullformatstringenumOutput image format.
pngjpgwebpdespillbooleanReduce background color spill around foreground edges.
channelsstringenumReturn the color image with transparency (rgba) or only the alpha mask (alpha).
rgbaalphaimage_fileobjectObligatorioImage file whose background will be removed.
environmentstringObligatorioenumChoose live for non-watermarked output that consumes plan credits, or sandbox for free watermarked output.
sandboxlivebackground_colorstringOptional output background color accepted by PhotoRoom instead of transparency.
Parámetros de salida
dataanyObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not