renameFile

Renames a specified file.

  • Arguments

    • key: The unique key of the file to rename.
    • name: The new name for the file.
  • Returns

    • A Promise<BreezeFileType|null> that resolves to the renamed file's details or null if the operation fails.
import { BreezeUploader } from "breeze-uploader-sdk";

const breeze = new BreezeUploader({
  apiKey: "YOUR_API_KEY",
  secretKey: "YOUR_SECRET_KEY",
});

await breeze.renameFile({ key: "YOUR_FILE_KEY", name: "NEW_NAME" });
Docs and examples licensed under MIT