Skip to main content

deleteRender()

Deletes a rendered video, audio or still and it's associated metada.

ts
import { deleteRender } from "@remotion/lambda";
 
const { freedBytes } = await deleteRender({
bucketName: "remotionlambda-r42fs9fk",
region: "us-east-1",
renderId: "8hfxlw",
});
 
console.log(freedBytes); // 21249541
ts
import { deleteRender } from "@remotion/lambda";
 
const { freedBytes } = await deleteRender({
bucketName: "remotionlambda-r42fs9fk",
region: "us-east-1",
renderId: "8hfxlw",
});
 
console.log(freedBytes); // 21249541

Arguments

An object with the following properties:

region

The AWS region in which the render has performed.

bucketName

The bucket name in which the render was stored. This should be the same variable you used for renderMediaOnLambda() or renderStillOnLambda().

renderId

The ID of the render. You can retrieve this ID by calling renderMediaOnLambda() or renderStillOnLambda().

customCredentials

optional, available from v3.2.23

If the render was saved to a different cloud, pass an object with the same endpoint, accessKeyId and secretAccessKey as you passed to renderMediaOnLambda() or renderStillOnLambda().

Return value

Returns a promise resolving to an object with the following properties:

freedBytes

The amount of bytes that were removed from the S3 bucket.

See also