bunny-client
Version:
TypeScript API Client for BunnyCDN 🐰
36 lines • 1.62 kB
TypeScript
import type { StorageHostname as StorageZoneEndpoint } from "../../../api/storage-zone/types";
export interface DownloadFileRequest {
/**
* The name that the file will be uploaded as.
* @example "demo.sqlite"
*/
fileName: string;
/**
* The directory path to where your file will be stored. If this is the root of your storage zone, you can ignore this parameter.
* @example "subpath"
*/
path?: string;
/**
* The storage API endpoint depends on the primary storage region of your storage zone. You can also find this in the FTP & HTTP API Information of your storage zone.
* @example "ny.storage.bunnycdn.com"
*/
storageZoneEndpoint?: StorageZoneEndpoint;
/**
* The name of your storage zone where you are connecting to.
* @example "example-storage-zone"
*/
storageZoneName?: string;
/**
* The storage zone password
* @example "22a5e2c4-0b5f-4fb0-bdb94eebb264-8944-4154"
*/
storageZonePassword?: string;
}
export type DownloadFileResponse = ArrayBuffer;
export declare const downloadFile: import("untypeable/dist/client-ca591958").g<DownloadFileRequest, ArrayBuffer>;
export declare const downloadFileEndpoints: {
readonly downloadFile: "downloadFile";
readonly "GET /:storageZoneName/:path/:fileName": "GET /:storageZoneName/:path/:fileName";
};
export declare function downloadFileClient(defaultRequestInit: RequestInit, { fileName, path, storageZoneEndpoint, storageZoneName, storageZonePassword, }: DownloadFileRequest): Promise<DownloadFileResponse>;
//# sourceMappingURL=downloadFile.d.ts.map