import { CloudinaryAssetConfiguration } from '@cloudinary-util/types'; import { CloudinaryImage, CloudinaryVideo } from '@cloudinary/url-gen'; import { IAnalyticsOptions } from '@cloudinary/url-gen/sdkAnalytics/interfaces/IAnalyticsOptions'; import { AspectRatio, CropMode, Gravity, Zoom, Height, Width, X, Y, PositionalOptions, Angle, FlagsDefinition, ListableFlags, Format, ListablePrompts, ExtractMode, Multiple } from './constants/parameters.js'; import { Q as QualifierConfig, a as QualifierConverters } from './qualifiers-NrbTECaq.js'; import { PluginResults } from './types/plugins.js'; declare namespace CroppingPlugin { interface Options { aspectRatio?: AspectRatio; crop?: CropMode | NestedOptions | ReadonlyArray; gravity?: Gravity; zoom?: Zoom; /** * @description Height of the given asset. */ height?: string | number; /** * @description Width of the given asset. */ width?: string | number; } interface NestedOptions { type: CropMode; aspectRatio?: AspectRatio; gravity?: Gravity; height?: Height; width?: Width; x?: X; y?: Y; zoom?: Zoom; source?: boolean; } } declare const CroppingPlugin: TransformationPlugin<"all", "Cropping", CroppingPlugin.Options, boolean>; declare const primary: { [k in OptionName]?: QualifierConfig; }; declare const position: { [k in keyof PositionalOptions]-?: QualifierConfig; }; declare const text: Record; interface QualifierOptions { angle?: Angle; /** * @description Applies the selected artistic filter. * @url https://cloudinary.com/documentation/transformation_reference#e_art */ art?: string; /** * @description Automatically adjusts the image brightness and blends the result with the original image. * @url https://cloudinary.com/documentation/transformation_reference#e_auto_brightness */ autoBrightness?: boolean | string; /** * @description Automatically adjusts the image color balance and blends the result with the original image. * @url https://cloudinary.com/documentation/transformation_reference#e_auto_color */ autoColor?: boolean | string; /** * @description Automatically adjusts the image contrast and blends the result with the original image. * @url https://cloudinary.com/documentation/transformation_reference#e_auto_contrast */ autoContrast?: boolean | string; /** * @description Applies stripes or color adjustment to help people with common color blind conditions to differentiate between colors that are similar for them. * @url https://cloudinary.com/documentation/transformation_reference#e_assist_colorblind */ assistColorblind?: boolean | string; /** * @description Applies a background to empty or transparent areas. * @url https://cloudinary.com/documentation/transformation_reference#b_background */ background?: string; /** * @description Converts an image to black and white. * @url https://cloudinary.com/documentation/transformation_reference#e_blackwhite */ blackwhite?: boolean | string; /** * @description Applies a blurring filter to an asset. * @url https://cloudinary.com/documentation/transformation_reference#e_blur */ blur?: boolean | string; /** * @description Blurs all detected faces in an image. * @url https://cloudinary.com/documentation/transformation_reference#e_blur_faces */ blurFaces?: boolean | string; /** * @description Applies a blurring filter to the region of an image specified by x, y, width and height, or an area of text. If no region is specified, the whole image is blurred. * @url https://cloudinary.com/documentation/transformation_reference#e_blur_region */ blurRegion?: boolean | string; /** * @description Adds a solid border around an image or video. * @url https://cloudinary.com/documentation/transformation_reference#bo_border */ border?: string; /** * @description Adjusts the image or video brightness. * @url https://cloudinary.com/documentation/transformation_reference#e_brightness */ brightness?: boolean | string; /** * @description Adjusts image brightness modulation in HSB to prevent artifacts in some images. * @url https://cloudinary.com/documentation/transformation_reference#e_brightness_hsb */ brightnessHSB?: boolean | string; /** * @description Applies a cartoon effect to an image. * @url https://cloudinary.com/documentation/transformation_reference#e_cartoonify */ cartoonify?: boolean | string; /** * @description A qualifier that specifies the color to use with the corresponding transformation. * @url https://cloudinary.com/documentation/transformation_reference#co_color */ color?: string; /** * @description Colorizes an image. By default, gray is used for colorization. You can specify a different color using the color qualifier. * @url https://cloudinary.com/documentation/transformation_reference#e_colorize */ colorize?: number | string; /** * @description Adjusts an image or video contrast. * @url https://cloudinary.com/documentation/transformation_reference#e_contrast */ contrast?: boolean | string; /** * @description Displaces the pixels in an image according to the color channels of the pixels in another specified image (a gradient map specified with the overlay parameter). * @url https://cloudinary.com/documentation/transformation_reference#e_displace */ displace?: string; /** * @description Distorts an image to a new shape by either adjusting its corners or by warping it into an arc. * @url https://cloudinary.com/documentation/transformation_reference#e_distort */ distort?: string; /** * @description Adjusts the fill light and optionally blends the result with the original image. * @url https://cloudinary.com/documentation/transformation_reference#e_fill_light */ fillLight?: boolean | string; /** * @description Adjusts the image or video gamma level. * @url https://cloudinary.com/documentation/transformation_reference#e_gamma */ gamma?: boolean | string; /** * @description Applies a gradient fade effect from the edge of an image. * @url https://cloudinary.com/documentation/transformation_reference#e_gradient_fade */ gradientFade?: boolean | string; /** * @description Converts an image to grayscale (multiple shades of gray). * @url https://cloudinary.com/documentation/transformation_reference#e_grayscale */ grayscale?: boolean; /** * @description Adjusts an image's hue. * @url https://cloudinary.com/documentation/transformation_reference#e_hue */ hue?: boolean | string; /** * @description Adjusts an image's colors, contrast and brightness to improve its appearance. * @url https://cloudinary.com/documentation/transformation_reference#e_improve */ improve?: boolean | string; /** * @description Loops a video or animated image the specified number of times. * @url https://cloudinary.com/documentation/transformation_reference#e_loop */ loop?: boolean | number | string; /** * @description A qualifier that blends image layers using the multiply blend mode. * @url https://cloudinary.com/documentation/transformation_reference#e_multiply */ multiply?: boolean; /** * @description https://cloudinary.com/documentation/transformation_reference#e_negate * @url https://cloudinary.com/documentation/transformation_reference#e_negate */ negate?: string | boolean; /** * @description https://cloudinary.com/documentation/transformation_reference#e_noise * @url https://cloudinary.com/documentation/transformation_reference#e_noise */ noise?: boolean; /** * @description https://cloudinary.com/documentation/transformation_reference#e_oil_paint * @url https://cloudinary.com/documentation/transformation_reference#e_oil_paint */ oilPaint?: string | boolean; /** * @description Adjusts the opacity of an asset and makes it semi-transparent. * @url https://cloudinary.com/documentation/transformation_reference#o_opacity */ opacity?: string | number; /** * @description Adds an outline effect to an image. * @url https://cloudinary.com/documentation/transformation_reference#e_outline */ outline?: boolean | string; /** * @description Applies a pixelation effect. * @url https://cloudinary.com/documentation/transformation_reference#e_pixelate */ pixelate?: boolean | string; /** * @description Pixelates all detected faces in an image. * @url https://cloudinary.com/documentation/transformation_reference#e_pixelate_faces */ pixelateFaces?: boolean | string; /** * @description Pixelates the region of an image specified by x, y, width and height, or an area of text. * @url https://cloudinary.com/documentation/transformation_reference#e_pixelate_region */ pixelateRegion?: boolean | string; /** * @description Rounds the corners of an image or video. * @url https://cloudinary.com/documentation/transformation_reference#r_round_corners */ radius?: string | number; /** * @description Automatically removes red eyes in an image. * @url https://cloudinary.com/documentation/transformation_reference#e_redeye */ redeye?: boolean | string; /** * @description Maps an input color and those similar to the input color to corresponding shades of a specified output color. * @url https://cloudinary.com/documentation/transformation_reference#e_replace_color */ replaceColor?: string; /** * @description Adjusts an image or video saturation level. * @url https://cloudinary.com/documentation/transformation_reference#e_saturation */ saturation?: boolean | string; /** * @description A qualifier that blends image layers using the screen blend mode. * @url https://cloudinary.com/documentation/transformation_reference#e_screen */ screen?: boolean; /** * @description Changes the color scheme of an image to sepia. * @url https://cloudinary.com/documentation/transformation_reference#e_sepia */ sepia?: boolean | string; /** * @description Adds a gray shadow to the bottom right of an image. * @url https://cloudinary.com/documentation/transformation_reference#e_shadow */ shadow?: boolean | string; /** * @description Applies a sharpening filter. * @url https://cloudinary.com/documentation/transformation_reference#e_sharpen */ sharpen?: boolean | string; /** * @description Skews an image according to the two specified values in degrees. * @url https://cloudinary.com/documentation/transformation_reference#e_shear */ shear?: string; /** * @description Simulates the way an image would appear to someone with the specified color blind condition. * @url https://cloudinary.com/documentation/transformation_reference#e_simulate_colorblind */ simulateColorblind?: boolean | string; /** * @description Blends an image with one or more tint colors at a specified intensity. * @url https://cloudinary.com/documentation/transformation_reference#e_tint */ tint?: boolean | string; /** * @description Detects and removes image edges whose color is similar to the corner pixels. * @url https://cloudinary.com/documentation/transformation_reference#e_trim */ trim?: boolean | string; /** * @description Applies an unsharp mask filter to an image. * @url https://cloudinary.com/documentation/transformation_reference#e_unsharp_mask */ unsharpMask?: boolean | string; /** * @description Vectorizes an image. * @url https://cloudinary.com/documentation/transformation_reference#e_vectorize */ vectorize?: boolean | string; /** * @description Applies a vibrance filter to an image. * @url https://cloudinary.com/documentation/transformation_reference#e_vibrance */ vibrance?: boolean | string; /** * @description Applies a vignette effect to an image. * @url https://cloudinary.com/documentation/transformation_reference#e_vignette */ vignette?: boolean | string; } declare const effects: { readonly angle: { readonly qualifier: "a"; }; readonly art: { readonly prefix: "e"; readonly qualifier: "art"; }; readonly autoBrightness: { readonly prefix: "e"; readonly qualifier: "auto_brightness"; }; readonly autoColor: { readonly prefix: "e"; readonly qualifier: "auto_color"; }; readonly autoContrast: { readonly prefix: "e"; readonly qualifier: "auto_contrast"; }; readonly assistColorblind: { readonly prefix: "e"; readonly qualifier: "assist_colorblind"; }; readonly background: { readonly qualifier: "b"; }; readonly blackwhite: { readonly prefix: "e"; readonly qualifier: "blackwhite"; }; readonly blur: { readonly prefix: "e"; readonly qualifier: "blur"; }; readonly blurFaces: { readonly prefix: "e"; readonly qualifier: "blur_faces"; }; readonly blurRegion: { readonly prefix: "e"; readonly qualifier: "blur_region"; }; readonly border: { readonly qualifier: "bo"; }; readonly brightness: { readonly prefix: "e"; readonly qualifier: "brightness"; }; readonly brightnessHSB: { readonly prefix: "e"; readonly qualifier: "brightness_hsb"; }; readonly cartoonify: { readonly prefix: "e"; readonly qualifier: "cartoonify"; }; readonly color: { readonly qualifier: "co"; readonly converters: QualifierConverters[]; }; readonly colorize: { readonly prefix: "e"; readonly qualifier: "colorize"; }; readonly contrast: { readonly prefix: "e"; readonly qualifier: "contrast"; }; readonly displace: { readonly prefix: "e"; readonly qualifier: "distort"; }; readonly distort: { readonly prefix: "e"; readonly qualifier: "distort"; }; readonly fillLight: { readonly prefix: "e"; readonly qualifier: "fill_light"; }; readonly gamma: { readonly prefix: "e"; readonly qualifier: "gamma"; }; readonly gradientFade: { readonly prefix: "e"; readonly qualifier: "gradient_fade"; }; readonly grayscale: { readonly prefix: "e"; readonly qualifier: "grayscale"; }; readonly hue: { readonly prefix: "e"; readonly qualifier: "hue"; }; readonly improve: { readonly prefix: "e"; readonly qualifier: "improve"; }; readonly loop: { readonly prefix: "e"; readonly qualifier: "loop"; }; readonly multiply: { readonly prefix: "e"; readonly qualifier: "multiply"; }; readonly negate: { readonly prefix: "e"; readonly qualifier: "negate"; }; readonly noise: { readonly prefix: "e"; readonly qualifier: "noise"; }; readonly oilPaint: { readonly prefix: "e"; readonly qualifier: "oil_paint"; }; readonly opacity: { readonly qualifier: "o"; }; readonly outline: { readonly prefix: "e"; readonly qualifier: "outline"; }; readonly pixelate: { readonly prefix: "e"; readonly qualifier: "pixelate"; }; readonly pixelateFaces: { readonly prefix: "e"; readonly qualifier: "pixelate_faces"; }; readonly pixelateRegion: { readonly prefix: "e"; readonly qualifier: "pixelate_region"; }; readonly radius: { readonly qualifier: "r"; }; readonly redeye: { readonly prefix: "e"; readonly qualifier: "redeye"; }; readonly replaceColor: { readonly prefix: "e"; readonly qualifier: "replace_color"; }; readonly saturation: { readonly prefix: "e"; readonly qualifier: "saturation"; }; readonly screen: { readonly prefix: "e"; readonly qualifier: "screen"; }; readonly sepia: { readonly prefix: "e"; readonly qualifier: "sepia"; }; readonly shadow: { readonly prefix: "e"; readonly qualifier: "shadow"; }; readonly sharpen: { readonly prefix: "e"; readonly qualifier: "sharpen"; }; readonly shear: { readonly prefix: "e"; readonly qualifier: "shear"; }; readonly simulateColorblind: { readonly prefix: "e"; readonly qualifier: "simulate_colorblind"; }; readonly tint: { readonly prefix: "e"; readonly qualifier: "tint"; }; readonly trim: { readonly prefix: "e"; readonly qualifier: "trim"; }; readonly unsharpMask: { readonly prefix: "e"; readonly qualifier: "unsharp_mask"; }; readonly vectorize: { readonly prefix: "e"; readonly qualifier: "vectorize"; }; readonly vibrance: { readonly prefix: "e"; readonly qualifier: "vibrance"; }; readonly vignette: { readonly prefix: "e"; readonly qualifier: "vignette"; }; }; declare namespace EffectsPlugin { interface NestableOptions extends QualifierOptions { } interface Options extends NestableOptions { /** * @description Array of objects specifying transformations to be applied to asset. */ effects?: ReadonlyArray; } } declare const EffectsPlugin: TransformationPlugin<"all", "Effects", EffectsPlugin.Options, boolean>; declare namespace FlagsPlugin { interface Options { flags?: FlagsDefinition; } } declare const FlagsPlugin: TransformationPlugin<"all", "Flags", FlagsPlugin.Options, boolean>; declare namespace NamedTransformationsPlugin { interface Options { /** * @description Named transformations to apply to asset. * @url https://cloudinary.com/documentation/image_transformations#named_transformations */ namedTransformations?: string | ReadonlyArray; /** * @deprecated use {@link `namedTransformations`} instead * @description: Deprecated: use namedTransformations instead * @url https://cloudinary.com/documentation/image_transformations#named_transformations */ transformations?: string | ReadonlyArray; } } declare const NamedTransformationsPlugin: TransformationPlugin<"all", "NamedTransformations", NamedTransformationsPlugin.Options, boolean>; declare const DEFAULT_TEXT_OPTIONS: { color: string; fontFamily: string; fontSize: number; fontWeight: string; }; declare namespace OverlaysPlugin { interface Options { /** * @description Image or text layers that are applied on top of the base image. * @url https://cloudinary.com/documentation/transformation_reference#l_layer */ overlays?: ReadonlyArray; /** * @description Text to be overlaid on asset. * @url https://cloudinary.com/documentation/image_transformations#transformation_url_structure */ text?: string | TextOptions; } interface NestedOptions { appliedEffects?: object[]; appliedFlags?: ListableFlags; effects?: object[]; crop?: CropMode; flags?: ListableFlags; height?: Height; position?: PositionalOptions; publicId?: string; text?: string | TextOptions; url?: string; width?: Width; } interface TextOptions { text: string; alignment?: string; antialias?: string; border?: string; color?: string; fontFamily?: string; fontSize?: number; fontStyle?: string | number; fontWeight?: string; hinting?: string | number; letterSpacing?: string | number; lineSpacing?: string | number; stroke?: boolean; } } declare const OverlaysPlugin: TransformationPlugin<"all", "Overlays", OverlaysPlugin.Options, boolean>; declare namespace PreserveTransformationsPlugin { interface Options { /** * @description Preserves transformations from a Cloudinary URL when using using a Cloudinary URL as the asset source (src). */ preserveTransformations?: boolean; } } declare const PreserveTransformationsPlugin: TransformationPlugin<"all", "PreserveTransformations", PreserveTransformationsPlugin.Options, boolean>; declare namespace RawTransformationsPlugin { interface Options { /** * @description Array of transformation parameters using the Cloudinary URL API to apply to an asset. * @url https://cloudinary.com/documentation/transformation_reference */ rawTransformations?: string | ReadonlyArray; } } declare const RawTransformationsPlugin: TransformationPlugin<"all", "RawTransformations", RawTransformationsPlugin.Options, boolean>; declare namespace RemoveBackgroundPlugin { interface Options { /** * @description Removes the background of an image using the Cloudinary AI Background Removal Add-On (Required). * @url https://cloudinary.com/documentation/cloudinary_ai_background_removal_addon */ removeBackground?: boolean; } } declare const RemoveBackgroundPlugin: TransformationPlugin<"image", "RemoveBackground", RemoveBackgroundPlugin.Options, boolean>; declare namespace SanitizePlugin { interface Options { /** * @description Runs a sanitizer on SVG images. * @url https://cloudinary.com/documentation/transformation_reference#fl_sanitize */ sanitize?: boolean; } } declare const SanitizePlugin: TransformationPlugin<"image", "Sanitize", SanitizePlugin.Options, true>; declare namespace SeoPlugin { interface Options { /** * @description Configures the URL to include an SEO-friendly suffix in the URL * @url https://cloudinary.com/documentation/advanced_url_delivery_options#seo_friendly_media_asset_urls */ seoSuffix?: string; } } declare const SeoPlugin: TransformationPlugin<"all", "Seo", SeoPlugin.Options, boolean>; declare namespace UnderlaysPlugin { interface Options { /** * @description Public ID of image that is applied under the base image. * @url https://cloudinary.com/documentation/transformation_reference#l_layer */ underlay?: string; /** * @description Image layers that are applied under the base image. * @url https://cloudinary.com/documentation/transformation_reference#l_layer */ underlays?: ReadonlyArray; } interface NestedOptions { appliedEffects?: ReadonlyArray; appliedFlags?: ListableFlags; effects?: ReadonlyArray; crop?: CropMode; flags?: ListableFlags; height?: Height; position?: PositionalOptions; publicId?: string; type?: string; url?: string; width?: Width; } } declare const UnderlaysPlugin: TransformationPlugin<"all", "Underlays", UnderlaysPlugin.Options, boolean>; declare namespace VersionPlugin { interface Options { /** * @description Custom version number to apply to asset URL. * @url https://cloudinary.com/documentation/advanced_url_delivery_options#asset_versions */ version?: number | string; } } declare const VersionPlugin: TransformationPlugin<"all", "Version", VersionPlugin.Options, boolean>; declare namespace ZoompanPlugin { interface Options { /** * @description Applies zooming and/or panning to an image, resulting in a video or animated image. * @url https://cloudinary.com/documentation/transformation_reference#e_zoompan */ zoompan?: string | boolean | NestedOptions; } interface NestedOptions { loop?: QualifierOptions["loop"]; options: string; } } declare const ZoompanPlugin: TransformationPlugin<"image", "Zoompan", ZoompanPlugin.Options, boolean>; type SupportedAssetTypeInput = SupportedAssetType | "videos" | "images"; interface BaseAssetOptions { /** * @description Cloudinary Public ID or versioned Cloudinary URL (/v1234/) */ src: string; /** * @description The type of asset to deliver. * @url https://cloudinary.com/documentation/image_transformations#transformation_url_structure */ assetType?: assetType; /** * @description Delivery method of the asset. * @url https://cloudinary.com/documentation/image_transformations#delivery_types */ deliveryType?: string; /** * @description Delivery method of the asset. * @url https://cloudinary.com/documentation/image_transformations#delivery_types */ dpr?: string | number; /** * @description Converts (if necessary) and delivers an asset in the specified format. * @url https://cloudinary.com/documentation/transformation_reference#f_format */ format?: Format; /** * @description Quality of the delivered asset * @url https://cloudinary.com/documentation/transformation_reference#q_quality */ quality?: string | number | string; /** * @description Gives you the ability to have more control over what transformations are permitted to be used from your Cloudinary account. * @url https://cloudinary.com/documentation/control_access_to_media#strict_transformations */ strictTransformations?: boolean; } interface AssetOptions extends BaseAssetOptions, CroppingPlugin.Options, EffectsPlugin.Options, FlagsPlugin.Options, NamedTransformationsPlugin.Options, OverlaysPlugin.Options, PreserveTransformationsPlugin.Options, RawTransformationsPlugin.Options, RemoveBackgroundPlugin.Options, SanitizePlugin.Options, SeoPlugin.Options, UnderlaysPlugin.Options, VersionPlugin.Options, ZoompanPlugin.Options { } declare namespace DefaultImagePlugin { interface Options { /** * @description Configures the default image to use in case the given public ID is not available. Must include file extension. * @url https://cloudinary.com/documentation/transformation_reference#d_default_image */ defaultImage?: string; } } declare const DefaultImagePlugin: TransformationPlugin<"image", "DefaultImage", DefaultImagePlugin.Options, boolean>; declare namespace EnhancePlugin { interface Options { /** * @description Uses AI to analyze an image and make adjustments to enhance the appeal of the image. * @url https://cloudinary.com/documentation/transformation_reference#e_enhance */ enhance?: boolean; } } declare const EnhancePlugin: TransformationPlugin<"image", "Enhance", EnhancePlugin.Options, boolean>; declare namespace ExtractPlugin { interface Options { /** * @description Extracts an area or multiple areas of an image, described in natural language. * @url https://cloudinary.com/documentation/transformation_reference#e_extract */ extract?: ListablePrompts | NestedOptions; } interface NestedOptions { prompt?: ListablePrompts; invert?: boolean; mode?: ExtractMode; multiple?: Multiple; } } declare const ExtractPlugin: TransformationPlugin<"image", "Extract", ExtractPlugin.Options, boolean>; declare namespace FillBackgroundPlugin { interface Options { /** * @description Uses Generative Fill to extended padded image with AI * @url https://cloudinary.com/documentation/transformation_reference#b_gen_fill */ fillBackground?: boolean | NestedOptions; } interface NestedOptions { crop?: CropMode; gravity?: Gravity; prompt?: ListablePrompts; seed?: number; } } declare const FillBackgroundPlugin: TransformationPlugin<"image", "FillBackground", FillBackgroundPlugin.Options, boolean>; declare namespace RecolorPlugin { interface Options { /** * @description Uses generative AI to recolor parts of your image, maintaining the relative shading. * @url https://cloudinary.com/documentation/transformation_reference#e_gen_recolor */ recolor?: string | ReadonlyArray | readonly [ReadonlyArray, ...Array] | NestedOptions; } interface NestedOptions { prompt?: ListablePrompts; to?: string; multiple?: boolean; } } declare const RecolorPlugin: TransformationPlugin<"image", "Recolor", RecolorPlugin.Options, boolean>; declare namespace RemovePlugin { interface Options { /** * @description Applies zooming and/or panning to an image, resulting in a video or animated image. * @url https://cloudinary.com/documentation/transformation_reference#e_zoompan */ remove?: ListablePrompts | NestedOptions; } interface NestedOptions { prompt?: ListablePrompts; region?: number[] | number[][]; multiple?: boolean; removeShadow?: boolean; } } declare const RemovePlugin: TransformationPlugin<"image", "Remove", RemovePlugin.Options, boolean>; declare namespace ReplaceBackgroundPlugin { interface Options { /** * @description Replaces the background of an image with an AI-generated background. * @url https://cloudinary.com/documentation/transformation_reference#e_gen_background_replace */ replaceBackground?: NestedOptions | string | boolean; } interface NestedOptions { prompt?: string; seed?: number; } } declare const ReplaceBackgroundPlugin: TransformationPlugin<"image", "ReplaceBackground", ReplaceBackgroundPlugin.Options, boolean>; declare namespace ReplacePlugin { interface Options { /** * @description Uses generative AI to replace parts of your image with something else. * @url https://cloudinary.com/documentation/transformation_reference#e_gen_replace */ replace?: NestedOptions | ReadonlyArray | ReadonlyArray; } interface NestedOptions { from: string; to: string; preserveGeometry?: boolean; } } declare const ReplacePlugin: TransformationPlugin<"image", "Replace", ReplacePlugin.Options, boolean>; declare namespace RestorePlugin { interface Options { /** * @description Uses generative AI to restore details in poor quality images or images that may have become degraded through repeated processing and compression. * @url https://cloudinary.com/documentation/transformation_reference#e_gen_restore */ restore?: boolean; } } declare const RestorePlugin: TransformationPlugin<"image", "Restore", RestorePlugin.Options, boolean>; interface ImageOptions extends AssetOptions, DefaultImagePlugin.Options, EnhancePlugin.Options, ExtractPlugin.Options, FillBackgroundPlugin.Options, RecolorPlugin.Options, RemovePlugin.Options, ReplacePlugin.Options, ReplaceBackgroundPlugin.Options, RestorePlugin.Options, ZoompanPlugin.Options { } interface VideoOptions extends AssetOptions, AbrPlugin.Options { } interface AllOptions extends AssetOptions, ImageOptions, VideoOptions { } type CloudinaryKey = keyof AllOptions & {}; type SupportedAssetType = "image" | "video" | "all"; type OptionName = keyof AllOptions; type ApplyWhen = OptionName | ((opts: AllOptions) => boolean); type AlwaysApply = () => true; interface PluginDefinition { name: name; supports: assetType; apply: PluginApplicationDefinition; inferOwnOptions: options; props: Record; alwaysApply?: alwaysApply; strict?: boolean; } interface TransformationPlugin { name: name; supports: assetType; apply: PluginApplication; inferOwnOptions: opts; props: Record; alwaysApply: alwaysApply; strict?: boolean; } type OwnOptionsParam = opts & ([alwaysApply] extends [true] ? {} : { [k in singleKeyOf]: Exclude; }); type CtxParam = assetType extends "all" ? AllOptions : assetType extends "video" | "videos" ? VideoOptions : ImageOptions; type singleKeyOf = { [k in keyof opts]: keyof opts extends k ? k : never; }[keyof opts]; type PluginApplicationDefinition = (cldAsset: CldAsset, /** Options owned by this plugin */ opts: OwnOptionsParam, ctx: CtxParam) => PluginResults; type PluginApplication = (cldAsset: CldAsset, opts: OwnOptionsParam & CtxParam) => PluginResults; declare const plugin: (def: PluginDefinition) => TransformationPlugin; declare namespace AbrPlugin { interface Options { /** * @description The streaming profile to apply when delivering a video using adaptive bitrate streaming. * @url https://cloudinary.com/documentation/transformation_reference#sp_streaming_profile */ streamingProfile?: string; } } declare const AbrPlugin: TransformationPlugin<"video", "Abr", AbrPlugin.Options, boolean>; declare const transformationPlugins: readonly [TransformationPlugin<"image", "Enhance", EnhancePlugin.Options, boolean>, TransformationPlugin<"image", "Extract", ExtractPlugin.Options, boolean>, TransformationPlugin<"image", "Recolor", RecolorPlugin.Options, boolean>, TransformationPlugin<"image", "RemoveBackground", RemoveBackgroundPlugin.Options, boolean>, TransformationPlugin<"image", "Remove", RemovePlugin.Options, boolean>, TransformationPlugin<"image", "Replace", ReplacePlugin.Options, boolean>, TransformationPlugin<"image", "ReplaceBackground", ReplaceBackgroundPlugin.Options, boolean>, TransformationPlugin<"image", "Restore", RestorePlugin.Options, boolean>, TransformationPlugin<"all", "Cropping", CroppingPlugin.Options, boolean>, TransformationPlugin<"all", "PreserveTransformations", PreserveTransformationsPlugin.Options, boolean>, TransformationPlugin<"all", "RawTransformations", RawTransformationsPlugin.Options, boolean>, TransformationPlugin<"video", "Abr", AbrPlugin.Options, boolean>, TransformationPlugin<"image", "DefaultImage", DefaultImagePlugin.Options, boolean>, TransformationPlugin<"all", "Effects", EffectsPlugin.Options, boolean>, TransformationPlugin<"image", "FillBackground", FillBackgroundPlugin.Options, boolean>, TransformationPlugin<"all", "Flags", FlagsPlugin.Options, boolean>, TransformationPlugin<"all", "Overlays", OverlaysPlugin.Options, boolean>, TransformationPlugin<"image", "Sanitize", SanitizePlugin.Options, true>, TransformationPlugin<"all", "NamedTransformations", NamedTransformationsPlugin.Options, boolean>, TransformationPlugin<"all", "Seo", SeoPlugin.Options, boolean>, TransformationPlugin<"all", "Underlays", UnderlaysPlugin.Options, boolean>, TransformationPlugin<"all", "Version", VersionPlugin.Options, boolean>, TransformationPlugin<"image", "Zoompan", ZoompanPlugin.Options, boolean>]; declare const cloudinaryPluginProps: Record; declare const cloudinaryPluginKeys: readonly CloudinaryKey[]; interface AnalyticsOptions extends IAnalyticsOptions { } interface ConfigOptions extends CloudinaryAssetConfiguration { } /** * @description Asset options (Image or Video) that define delivery URL including public ID and transformations. * @path /url-loader/assetoptions */ type OptionsInput = ImageOptions | VideoOptions; /** * constructCloudinaryUrl * @description Builds a full Cloudinary URL using transformation plugins specified by options */ interface ConstructUrlProps { /** * @description Tech, dependency, and feature identifiers for tracking SDK usage related to Cloudinary. * @path /url-loader/analyticsoptions */ analytics?: AnalyticsOptions | boolean; /** * @description Configuration parameters for environment and Cloudinary account. * @url https://cloudinary.com/documentation/cloudinary_sdks#configuration_parameters * @path /url-loader/analyticsoptions */ config?: ConfigOptions; options: { assetType?: assetType; } & CtxParam; } type CldAsset = CloudinaryImage | CloudinaryVideo; declare function constructCloudinaryUrl({ options, config, analytics }: ConstructUrlProps): string; /** * searchAssetRawTransformations * @description Given a CloudinaryImage or CloudinaryVideo, searches raw transformations applied to the instance */ interface SearchAssetRawTransformationsOptions { matchType: string; } declare function searchAssetRawTransformations(query: string, asset: CloudinaryImage | CloudinaryVideo, options?: SearchAssetRawTransformationsOptions): boolean | undefined; export { AbrPlugin as $, type AnalyticsOptions as A, type BaseAssetOptions as B, type ConfigOptions as C, DEFAULT_TEXT_OPTIONS as D, EffectsPlugin as E, FlagsPlugin as F, type SupportedAssetType as G, type OptionName as H, type ImageOptions as I, type ApplyWhen as J, type AlwaysApply as K, type PluginDefinition as L, type OwnOptionsParam as M, NamedTransformationsPlugin as N, OverlaysPlugin as O, PreserveTransformationsPlugin as P, type QualifierOptions as Q, RawTransformationsPlugin as R, SanitizePlugin as S, type TransformationPlugin as T, UnderlaysPlugin as U, type VideoOptions as V, type CtxParam as W, type PluginApplicationDefinition as X, type PluginApplication as Y, ZoompanPlugin as Z, plugin as _, cloudinaryPluginProps as a, type OptionsInput as a0, type CldAsset as a1, searchAssetRawTransformations as a2, constructCloudinaryUrl as b, cloudinaryPluginKeys as c, type ConstructUrlProps as d, effects as e, primary as f, text as g, type AssetOptions as h, CroppingPlugin as i, RemoveBackgroundPlugin as j, SeoPlugin as k, VersionPlugin as l, type SupportedAssetTypeInput as m, DefaultImagePlugin as n, EnhancePlugin as o, position as p, ExtractPlugin as q, FillBackgroundPlugin as r, RecolorPlugin as s, transformationPlugins as t, RemovePlugin as u, ReplaceBackgroundPlugin as v, ReplacePlugin as w, RestorePlugin as x, type AllOptions as y, type CloudinaryKey as z };