Skip to content

Commit 4f71872

Browse files
authored
Add missing type definition (#677)
* Add type definition for download_folder function
1 parent 060a5e2 commit 4f71872

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

types/cloudinary_ts_spec.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -911,6 +911,16 @@ cloudinary.v2.utils.download_zip_url(
911911
}
912912
);
913913

914+
// $ExpectType string
915+
cloudinary.v2.utils.download_folder(
916+
'my-folder',
917+
{
918+
resource_type: 'image',
919+
prefixes: 'photos/'
920+
}
921+
);
922+
923+
914924
// $ExpectType { [key: string]: any; signature: string; api_key: string; }
915925
cloudinary.v2.utils.sign_request(
916926
{}

types/index.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -924,6 +924,8 @@ declare module 'cloudinary' {
924924

925925
function download_zip_url(options?: ArchiveApiOptions | ConfigAndUrlOptions): string;
926926

927+
function download_folder(folder_path: string, options?: ArchiveApiOptions | ConfigAndUrlOptions): string;
928+
927929
function download_backedup_asset(asset_id?: string, version_id?: string, options?: ArchiveApiOptions | ConfigAndUrlOptions): string
928930

929931
function generate_auth_token(options?: AuthTokenApiOptions): string;

0 commit comments

Comments
 (0)