Cloudinary
Upload and transform images and media with Cloudinary.
On this page
Connect
Auth type: API key (secret_text). Pass the provider's API key or token as the connection's credential. It is sealed at rest and only opened on the server when an action runs.
- From your agent: integrations {action: "connect", piece, credentials, env} stores the credentials for dev, prod or all. Answers name the fields, never the values.
- Or set the integration's project secrets with the secrets tool (SLACK_BOT_TOKEN, DISCORD_WEBHOOK_URL, TELEGRAM_BOT_TOKEN, TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN …): a call uses the connection, else those secrets. integrations {action: "catalog", piece} lists which ones work.
- Try one action now with integrations {action: "call", piece, piece_action, input}. It really sends.
Call it from a workflow
step.ctx.integrations.invoke("cloudinary", action, input) resolves with the provider's answer and rejects when Cloudinary isn't connected or refuses. Wrap it in step.run so a retry sends once. See step.ctx. Its actions run through the integration runner, which the server's operator turns on: integrations {action: "catalog", piece: "cloudinary"} says whether yours can call it.
// workflows/notify.ts: call Cloudinary when a booking is confirmed
import { on } from "@appbricx/workflows";
export const tellCloudinary = on.transition("booking", "status", "confirmed", async (_event, step) => {
// Recorded once: a retry doesn't send it twice. Rejects when Cloudinary isn't connected.
const output = await step.run("Cloudinary", () =>
step.ctx.integrations.invoke("cloudinary", "transformResource", {
"resource_type": "<resource_type>"
}),
);
step.ctx.log("Cloudinary answered", output);
});{
"name": "integrations",
"arguments": {
"project_id": "<project-id>",
"action": "call",
"piece": "cloudinary",
"piece_action": "transformResource",
"input": {
"resource_type": "<resource_type>"
},
"env": "dev"
}
}curl -X POST "$APP_ORIGIN/__appbricx/connector-proxy/cloudinary/transformResource" \
-H "Authorization: Bearer $APP_KEY" \
-H "content-type: application/json" \
-d '{"props":{"resource_type":"<resource_type>"}}'Actions
transformResource
Transform Resource. Apply transformations (resize, crop, watermark, etc.) to an asset and generate a new URL.
| Input | Type | Description |
|---|---|---|
resource_typerequired | id (picked from your account) | Select the type of resource to upload to Cloudinary. |
public_ids_dropdownoptional | ids (picked from your account) | Select assets to delete by their public IDs |
public_id_manualoptional | text | Or enter public ID manually if not in dropdown |
widthoptional | number | Target width in pixels |
heightoptional | number | Target height in pixels |
crop_modeoptional | one of "scale" | "fill" | "fit" | "crop" | "thumb" | "limit" | How to handle resizing when aspect ratios differ |
gravityoptional | one of "auto" | "face" | "center" | "north" | "south" | "east" | "west" | "north_west" | "north_east" | "south_west" | "south_east" | Which part to focus on when cropping |
formatoptional | one of "auto" | "jpg" | "png" | "webp" | "avif" | "gif" | "svg" | Convert to this format |
qualityoptional | one of "auto" | "90" | "80" | "70" | "50" | Image quality/compression level |
borderoptional | text | Add border (e.g., "5px_solid_blue", "10px_solid_#ff0000") |
radiusoptional | one of "10" | "20" | "50" | "max" | Round corners or make circular |
opacityoptional | number | Transparency level (0-100, where 100 is opaque) |
rotationoptional | number | Rotate image by degrees (0-360) |
raw_transformationoptional | long text | Advanced: Raw transformation string (e.g., "c_fill,w_300,h_200/e_sepia/r_20"). This will be applied after the above basic transformations. |
generate_url_onlyoptional | boolean | If true, only return the transformation URL. If false, also make a request to generate the transformed asset. |
createUsageReport
Create Usage Report. Generate a comprehensive report of account usage and quotas including storage, bandwidth, transformations, requests, and add-on usage.
| Input | Type | Description |
|---|---|---|
dateoptional | date-time (ISO) | Date for the usage report. Must be within the last 3 months. Leave empty for current date. |
include_breakdownoptional | boolean | Whether to include detailed breakdown of transformation types and add-on usage in the response. |
deleteResource
Delete Resource. Permanently delete images, videos, or files from Cloudinary.
| Input | Type | Description |
|---|---|---|
deletion_moderequired | one of "public_ids" | "tag" | "prefix" | Choose how to specify assets for deletion |
resource_typerequired | id (picked from your account) | Select the type of resource to upload to Cloudinary. |
public_ids_dropdownoptional | ids (picked from your account) | Select assets to delete by their public IDs |
public_ids_manualoptional | long text | Or type comma-separated public IDs manually (up to 100). Example: image1,image2,folder/image3 |
tag_dropdownoptional | id (picked from your account) | Select existing tags or type new ones (comma-separated) |
tag_manualoptional | text | Or type tag name manually to delete all assets with this tag (up to 1000 assets) |
prefixoptional | text | Delete all assets whose public ID starts with this prefix (up to 1000 assets) |
typeoptional | one of "upload" | "private" | "authenticated" | The delivery type of assets to delete |
keep_originaloptional | boolean | Delete only derived assets, keep the original |
invalidateoptional | boolean | Whether to invalidate CDN cached copies. Takes a few minutes to propagate. |
findResourceByPublicId
Find Resource by Public ID. Retrieve details of an asset using its unique public ID.
| Input | Type | Description |
|---|---|---|
resource_typerequired | id (picked from your account) | Select the type of resource to upload to Cloudinary. |
public_id_dropdownoptional | id (picked from your account) | Select an asset to find by its public ID |
public_id_manualoptional | text | Or enter the public ID manually if not found in dropdown (e.g., "sample", "folder/image-name") |
delivery_typeoptional | one of "upload" | "private" | "authenticated" | The delivery type of the asset |
uploadResource
Upload Resource. Upload a new image, video, or file to Cloudinary.
| Input | Type | Description |
|---|---|---|
filerequired | file | The file to upload to Cloudinary. |
public_idoptional | text | The public ID for the uploaded resource. If not specified, a random ID will be generated. |
folderoptional | id (picked from your account) | Select an existing folder or type a new folder path (e.g., "samples/animals") |
tagsoptional | ids (picked from your account) | Select existing tags or type new ones |
overwriteoptional | boolean | Whether to overwrite existing assets with the same public ID. |
use_filenameoptional | boolean | Whether to use the original file name as the public ID. |
Details
- Id
cloudinary- Category
- Other
- Tags
- images, media, cdn, transformation
- Package
@activepieces/piece-cloudinary@0.1.3- Runs
- Through the integration runner