Methods
-
addAction( action ) → {this}
-
addTransformation( tx ) → {this}
-
Description
Allows the injection of a raw transformation as a string into the transformation, or a Transformation instance that was previously created
Parameters
Name Type Description tx
string | SDK.Transformation Returns
Examples
import {Transformation} from "@cloudinary/url-gen"; const transformation = new Transformation(); transformation.addTransformation('w_100/w_200/w_300');
Details
-
toString() → {string}
-
Returns
Details
-
animated( animatedAction ) → {this}
-
Description
Delivers an animated GIF.
Parameters
Name Type Description animatedAction
AnimatedAction Returns
Details
-
border( borderAction ) → {this}
-
Description
Adds a border around the image.
Parameters
Name Type Description borderAction
Border Returns
Details
-
reshape( reshapeAction ) → {this}
-
Description
Adjusts the shape of the delivered image. Learn more: Shape changes and distortion effects
Parameters
Name Type Description reshapeAction
IReshape Returns
Details
-
resize( resizeAction ) → {this}
-
Description
Resize the asset using provided resize action
Parameters
Name Type Description resizeAction
ResizeSimpleAction Returns
Details
-
quality( quality ) → {this}
-
Description
An alias to Action Delivery.quality
Parameters
Name Type Description quality
string | number Returns
Details
-
format( format ) → {this}
-
Description
An alias to Action Delivery.format
Parameters
Name Type Description format
string Returns
Details
-
roundCorners( roundCornersAction ) → {this}
-
Description
Rounds the specified corners of an image.
Parameters
Name Type Description roundCornersAction
Returns
Details
-
overlay( overlayAction ) → {this}
-
Description
Adds an overlay over the base image.
Parameters
Name Type Description overlayAction
LayerAction Returns
Details
-
underlay( underlayAction ) → {this}
-
Description
Adds an underlay under the base image.
Parameters
Name Type Description underlayAction
LayerAction Returns
Details
-
addVariable( variableAction ) → {this}
-
Description
Defines an new user variable.
Parameters
Name Type Description variableAction
VariableAction Returns
Details
-
conditional( conditionAction ) → {this}
-
Description
Specifies a condition to be met before applying a transformation.
Parameters
Name Type Description conditionAction
ConditionalAction Returns
Details
-
effect( effectAction ) → {this}
-
Description
Applies a filter or an effect on an asset.
Parameters
Name Type Description effectAction
SimpleEffectAction Returns
Details
-
adjust( action ) → {this}
-
Description
Applies adjustment effect on an asset.
Parameters
Name Type Description action
Returns
Details
-
rotate( rotateAction ) → {this}
-
Description
Rotates the asset by the given angle.
Parameters
Name Type Description rotateAction
RotateAction Returns
Details
-
namedTransformation( namedTransformation ) → {this}
-
Description
Applies a pre-defined named transformation of the given name.
Parameters
Name Type Description namedTransformation
NamedTransformation Returns
Details
-
delivery( deliveryAction ) → {this}
-
Description
Applies delivery action.
Parameters
Name Type Description deliveryAction
Returns
Details
-
backgroundColor( color ) → {this}
-
Description
Sets the color of the background.
Parameters
Name Type Description color
Qualifiers.Color Returns
Details
-
psdTools( action ) → {this}
-
Description
Adds a layer in a Photoshop document.
Parameters
Name Type Description action
Returns
Details
-
extract( action ) → {this}
-
Description
Extracts an image or a page using an index, a range, or a name from a layered media asset.
Parameters
Name Type Description action
Returns
Details
-
addFlag( flagQualifier ) → {this}
-
Description
Adds a flag as a separate action.
Parameters
Name Type Description flagQualifier
Qualifiers.Flag | string Returns
Details
-
customFunction() → {this}
-
Description
Inject a custom function into the image transformation pipeline.
Returns
Details
-
transcode( action ) → {this}
-
Description
Transcodes the video (or audio) to another format.
Parameters
Name Type Description action
Action Returns
Details
-
videoEdit( action ) → {this}
-
Description
Applies the specified video edit action.
Parameters
Name Type Description action
videoEditType Returns
Details