@internxt/sdk 1.12.0 → 1.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,7 +3,7 @@ import { ApiSecurity, ApiUrl, AppDetails } from '../../shared';
3
3
  import { RequestCanceler } from '../../shared/http/client';
4
4
  import { UUID } from '../../shared/types/userSettings';
5
5
  import { ItemType } from './../../workspaces/types';
6
- import { AddItemsToTrashPayload, CheckDuplicatedFilesPayload, CheckDuplicatedFilesResponse, CheckDuplicatedFolderPayload, CheckDuplicatedFoldersResponse, CreateFolderByUuidPayload, CreateFolderPayload, CreateFolderResponse, CreateThumbnailEntryPayload, DeleteFilePayload, DriveFileData, FetchFolderContentResponse, FetchLimitResponse, FetchPaginatedFilesContent, FetchPaginatedFolderContentResponse, FetchPaginatedFoldersContent, FileEntry, FileEntryByUuid, FileMeta, FileVersion, FolderAncestor, FolderAncestorWorkspace, FolderMeta, FolderTreeResponse, FileLimitsResponse, MoveFilePayload, MoveFileResponse, MoveFileUuidPayload, MoveFolderPayload, MoveFolderResponse, MoveFolderUuidPayload, ReplaceFile, RestoreFileVersionResponse, SearchResultData, Thumbnail, ThumbnailEntry, UpdateFilePayload, UpdateFolderMetadataPayload, UsageResponse, UsageResponseV2 } from './types';
6
+ import { AddItemsToTrashPayload, CheckDuplicatedFilesPayload, CheckDuplicatedFilesResponse, CheckDuplicatedFolderPayload, CheckDuplicatedFoldersResponse, CreateFolderByUuidPayload, CreateFolderPayload, CreateFolderResponse, CreateThumbnailEntryPayload, DeleteFilePayload, DriveFileData, FetchFolderContentResponse, FetchLimitResponse, FetchPaginatedFilesContent, FetchPaginatedFolderContentResponse, FetchPaginatedFoldersContent, FileEntry, FileEntryByUuid, FileMeta, FileVersion, FolderAncestor, FolderAncestorWorkspace, FolderMeta, FolderStatsResponse, FolderTreeResponse, FileLimitsResponse, MoveFilePayload, MoveFileResponse, MoveFileUuidPayload, MoveFolderPayload, MoveFolderResponse, MoveFolderUuidPayload, ReplaceFile, RestoreFileVersionResponse, SearchResultData, Thumbnail, ThumbnailEntry, UpdateFilePayload, UpdateFolderMetadataPayload, UsageResponse, UsageResponseV2 } from './types';
7
7
  export * as StorageTypes from './types';
8
8
  export declare class Storage {
9
9
  private readonly client;
@@ -307,6 +307,13 @@ export declare class Storage {
307
307
  * @returns {Promise<FolderMeta>}
308
308
  */
309
309
  getFolderMeta(uuid: string, workspacesToken?: string, resourcesToken?: string): Promise<FolderMeta>;
310
+ /**
311
+ * Gets the stats of a given folder UUID
312
+ *
313
+ * @param {string} uuid - UUID of the folder.
314
+ * @returns {Promise<FolderStatsResponse>}
315
+ */
316
+ getFolderStats(uuid: string): Promise<FolderStatsResponse>;
310
317
  /**
311
318
  * Gets the meta of a given folder Id
312
319
  *
@@ -615,6 +615,15 @@ var Storage = /** @class */ (function () {
615
615
  : undefined;
616
616
  return this.client.get("folders/".concat(uuid, "/meta"), (0, headers_1.addResourcesTokenToHeaders)(this.headers(customHeaders), resourcesToken));
617
617
  };
618
+ /**
619
+ * Gets the stats of a given folder UUID
620
+ *
621
+ * @param {string} uuid - UUID of the folder.
622
+ * @returns {Promise<FolderStatsResponse>}
623
+ */
624
+ Storage.prototype.getFolderStats = function (uuid) {
625
+ return this.client.get("folders/".concat(uuid, "/stats"), this.headers());
626
+ };
618
627
  /**
619
628
  * Gets the meta of a given folder Id
620
629
  *
@@ -111,6 +111,7 @@ export interface FetchFolderContentResponse {
111
111
  files: DriveFileData[];
112
112
  }
113
113
  export type FileMeta = paths['/files/{uuid}/meta']['get']['responses']['200']['content']['application/json'];
114
+ export type FolderStatsResponse = paths['/folders/{uuid}/stats']['get']['responses']['200']['content']['application/json'];
114
115
  export interface ShareLink {
115
116
  id: string;
116
117
  token: string;
package/dist/schema.d.ts CHANGED
@@ -3061,7 +3061,7 @@ export interface components {
3061
3061
  */
3062
3062
  bucket: string;
3063
3063
  /**
3064
- * @description The ID of the file (required when size > 0)
3064
+ * @description The ID of the file (required when size > 0, must not be provided when size = 0)
3065
3065
  * @example file12345
3066
3066
  */
3067
3067
  fileId?: string;
@@ -3167,7 +3167,7 @@ export interface components {
3167
3167
  };
3168
3168
  ReplaceFileDto: {
3169
3169
  /**
3170
- * @description File id (required when size > 0)
3170
+ * @description File id (required when size > 0, must not be provided when size = 0)
3171
3171
  * @example 651300a2da9b27001f63f384
3172
3172
  */
3173
3173
  fileId?: string;
@@ -3903,7 +3903,7 @@ export interface components {
3903
3903
  */
3904
3904
  bucket: string;
3905
3905
  /**
3906
- * @description The ID of the file (required when size > 0)
3906
+ * @description The ID of the file (required when size > 0, must not be provided when size = 0)
3907
3907
  * @example file12345
3908
3908
  */
3909
3909
  fileId?: string;
@@ -8696,7 +8696,7 @@ export interface operations {
8696
8696
  };
8697
8697
  };
8698
8698
  responses: {
8699
- /** @description Incomplete checkout email sent successfully */
8699
+ /** @description Incomplete checkout processed successfully */
8700
8700
  200: {
8701
8701
  headers: {
8702
8702
  [name: string]: unknown;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@internxt/sdk",
3
3
  "author": "Internxt <hello@internxt.com>",
4
- "version": "1.12.0",
4
+ "version": "1.12.1",
5
5
  "description": "An sdk for interacting with Internxt's services",
6
6
  "repository": {
7
7
  "type": "git",