Skip to content

Commit

Permalink
Merge pull request #153 from internxt/feature/add-call-to-get-share-d…
Browse files Browse the repository at this point in the history
…omains

[PB-119] feature/Rotate drive sharing file drive subdomain
  • Loading branch information
CandelR authored Jul 13, 2023
2 parents 129154e + 0bdecec commit 3512095
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/drive/share/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
GetSharedDirectoryPayload,
GetShareLinkFolderSizePayload,
ListShareLinksResponse,
ShareDomainsResponse,
ShareLink,
UpdateShareLinkPayload,
} from './types';
Expand Down Expand Up @@ -133,6 +134,9 @@ export class Share {
);
}

public getShareDomains(): Promise<ShareDomainsResponse> {
return this.client.get('/storage/share/domains', this.headers());
}
/**
* Get size of folder in share links
* @param payload
Expand Down
4 changes: 4 additions & 0 deletions src/drive/share/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ export interface SharedDirectoryFile {
encryptionKey: string;
}

export interface ShareDomainsResponse {
list: string[];
}

export type ListShareLinksItem = Pick<
ShareLink,
'id' | 'token' | 'views' | 'timesValid' | 'active' | 'isFolder' | 'createdAt' | 'updatedAt' | 'fileSize'
Expand Down

0 comments on commit 3512095

Please sign in to comment.