frameio 1.2.1 → 1.2.3
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.
- package/README.md +1 -1
- package/dist/cjs/Client.js +2 -2
- package/dist/cjs/api/resources/accountPermissions/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/accountPermissions/client/Client.js +66 -79
- package/dist/cjs/api/resources/accounts/client/Client.d.ts +3 -2
- package/dist/cjs/api/resources/accounts/client/Client.js +67 -74
- package/dist/cjs/api/resources/comments/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/comments/client/Client.js +69 -82
- package/dist/cjs/api/resources/files/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/files/client/Client.js +4 -1
- package/dist/cjs/api/resources/folders/client/Client.d.ts +1 -1
- package/dist/cjs/api/resources/folders/client/Client.js +4 -1
- package/dist/cjs/api/resources/folders/types/FoldersListRequestInclude.d.ts +1 -0
- package/dist/cjs/api/resources/folders/types/FoldersListRequestInclude.js +1 -0
- package/dist/cjs/api/resources/folders/types/FoldersShowRequestInclude.d.ts +1 -0
- package/dist/cjs/api/resources/folders/types/FoldersShowRequestInclude.js +1 -0
- package/dist/cjs/api/resources/metadata/client/Client.d.ts +4 -4
- package/dist/cjs/api/resources/metadata/client/Client.js +4 -4
- package/dist/cjs/api/resources/metadata/client/requests/BulkUpdateMetadataParams.d.ts +4 -4
- package/dist/cjs/api/resources/projectPermissions/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/projectPermissions/client/Client.js +66 -76
- package/dist/cjs/api/resources/projects/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/projects/client/Client.js +66 -79
- package/dist/cjs/api/resources/shares/client/Client.d.ts +8 -6
- package/dist/cjs/api/resources/shares/client/Client.js +130 -153
- package/dist/cjs/api/resources/shares/client/requests/AddAssetParams.d.ts +1 -1
- package/dist/cjs/api/resources/shares/client/requests/CreateShareParams.d.ts +2 -2
- package/dist/cjs/api/resources/shares/client/requests/UpdateShareParams.d.ts +1 -1
- package/dist/cjs/api/resources/versionStacks/client/Client.d.ts +2 -2
- package/dist/cjs/api/resources/versionStacks/client/Client.js +5 -2
- package/dist/cjs/api/resources/versionStacks/client/requests/VersionStackCreateParams.d.ts +1 -1
- package/dist/cjs/api/resources/webhooks/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/webhooks/client/Client.js +66 -79
- package/dist/cjs/api/resources/workspacePermissions/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/workspacePermissions/client/Client.js +66 -76
- package/dist/cjs/api/resources/workspaces/client/Client.d.ts +2 -1
- package/dist/cjs/api/resources/workspaces/client/Client.js +69 -79
- package/dist/cjs/api/types/AssetInclude.d.ts +1 -0
- package/dist/cjs/api/types/AssetInclude.js +1 -0
- package/dist/cjs/api/types/{AuditLogsResponse.d.ts → AuditLogsWithIncludesResponse.d.ts} +1 -1
- package/dist/cjs/api/types/{AssetsWithIncludesResponse.d.ts → FileAssetsWithIncludesResponse.d.ts} +1 -1
- package/dist/cjs/api/types/FolderAssetsWithIncludesResponse.d.ts +8 -0
- package/dist/cjs/api/types/{UserRolesResponse.d.ts → ProjectUserRolesResponse.d.ts} +1 -1
- package/dist/cjs/api/types/ProjectUserRolesResponse.js +3 -0
- package/dist/cjs/api/types/VersionStackAssetsWithIncludesResponse.d.ts +8 -0
- package/dist/cjs/api/types/VersionStackAssetsWithIncludesResponse.js +3 -0
- package/dist/cjs/api/types/WorkspaceUserRolesResponse.d.ts +11 -0
- package/dist/cjs/api/types/WorkspaceUserRolesResponse.js +3 -0
- package/dist/cjs/api/types/index.d.ts +6 -3
- package/dist/cjs/api/types/index.js +6 -3
- package/dist/cjs/core/index.d.ts +0 -2
- package/dist/cjs/core/index.js +0 -2
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/Client.mjs +2 -2
- package/dist/esm/api/resources/accountPermissions/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/accountPermissions/client/Client.mjs +66 -79
- package/dist/esm/api/resources/accounts/client/Client.d.mts +3 -2
- package/dist/esm/api/resources/accounts/client/Client.mjs +67 -74
- package/dist/esm/api/resources/comments/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/comments/client/Client.mjs +69 -82
- package/dist/esm/api/resources/files/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/files/client/Client.mjs +4 -1
- package/dist/esm/api/resources/folders/client/Client.d.mts +1 -1
- package/dist/esm/api/resources/folders/client/Client.mjs +4 -1
- package/dist/esm/api/resources/folders/types/FoldersListRequestInclude.d.mts +1 -0
- package/dist/esm/api/resources/folders/types/FoldersListRequestInclude.mjs +1 -0
- package/dist/esm/api/resources/folders/types/FoldersShowRequestInclude.d.mts +1 -0
- package/dist/esm/api/resources/folders/types/FoldersShowRequestInclude.mjs +1 -0
- package/dist/esm/api/resources/metadata/client/Client.d.mts +4 -4
- package/dist/esm/api/resources/metadata/client/Client.mjs +4 -4
- package/dist/esm/api/resources/metadata/client/requests/BulkUpdateMetadataParams.d.mts +4 -4
- package/dist/esm/api/resources/projectPermissions/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/projectPermissions/client/Client.mjs +66 -76
- package/dist/esm/api/resources/projects/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/projects/client/Client.mjs +66 -79
- package/dist/esm/api/resources/shares/client/Client.d.mts +8 -6
- package/dist/esm/api/resources/shares/client/Client.mjs +130 -153
- package/dist/esm/api/resources/shares/client/requests/AddAssetParams.d.mts +1 -1
- package/dist/esm/api/resources/shares/client/requests/CreateShareParams.d.mts +2 -2
- package/dist/esm/api/resources/shares/client/requests/UpdateShareParams.d.mts +1 -1
- package/dist/esm/api/resources/versionStacks/client/Client.d.mts +2 -2
- package/dist/esm/api/resources/versionStacks/client/Client.mjs +5 -2
- package/dist/esm/api/resources/versionStacks/client/requests/VersionStackCreateParams.d.mts +1 -1
- package/dist/esm/api/resources/webhooks/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/webhooks/client/Client.mjs +66 -79
- package/dist/esm/api/resources/workspacePermissions/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/workspacePermissions/client/Client.mjs +66 -76
- package/dist/esm/api/resources/workspaces/client/Client.d.mts +2 -1
- package/dist/esm/api/resources/workspaces/client/Client.mjs +69 -79
- package/dist/esm/api/types/AssetInclude.d.mts +1 -0
- package/dist/esm/api/types/AssetInclude.mjs +1 -0
- package/dist/esm/api/types/{AuditLogsResponse.d.mts → AuditLogsWithIncludesResponse.d.mts} +1 -1
- package/dist/esm/api/types/{AssetsWithIncludesResponse.d.mts → FileAssetsWithIncludesResponse.d.mts} +1 -1
- package/dist/esm/api/types/FolderAssetsWithIncludesResponse.d.mts +8 -0
- package/dist/esm/api/types/{UserRolesResponse.d.mts → ProjectUserRolesResponse.d.mts} +1 -1
- package/dist/esm/api/types/ProjectUserRolesResponse.mjs +2 -0
- package/dist/esm/api/types/VersionStackAssetsWithIncludesResponse.d.mts +8 -0
- package/dist/esm/api/types/VersionStackAssetsWithIncludesResponse.mjs +2 -0
- package/dist/esm/api/types/WorkspaceUserRolesResponse.d.mts +11 -0
- package/dist/esm/api/types/WorkspaceUserRolesResponse.mjs +2 -0
- package/dist/esm/api/types/index.d.mts +6 -3
- package/dist/esm/api/types/index.mjs +6 -3
- package/dist/esm/core/index.d.mts +0 -2
- package/dist/esm/core/index.mjs +0 -2
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -1
- package/reference.md +42 -216
- package/dist/cjs/core/pagination/Page.d.ts +0 -32
- package/dist/cjs/core/pagination/Page.js +0 -100
- package/dist/cjs/core/pagination/Pageable.d.ts +0 -14
- package/dist/cjs/core/pagination/Pageable.js +0 -10
- package/dist/cjs/core/pagination/index.d.ts +0 -2
- package/dist/cjs/core/pagination/index.js +0 -7
- package/dist/cjs/core/utils/index.d.ts +0 -1
- package/dist/cjs/core/utils/index.js +0 -5
- package/dist/cjs/core/utils/setObjectProperty.d.ts +0 -11
- package/dist/cjs/core/utils/setObjectProperty.js +0 -42
- package/dist/esm/core/pagination/Page.d.mts +0 -32
- package/dist/esm/core/pagination/Page.mjs +0 -96
- package/dist/esm/core/pagination/Pageable.d.mts +0 -14
- package/dist/esm/core/pagination/Pageable.mjs +0 -6
- package/dist/esm/core/pagination/index.d.mts +0 -2
- package/dist/esm/core/pagination/index.mjs +0 -2
- package/dist/esm/core/utils/index.d.mts +0 -1
- package/dist/esm/core/utils/index.mjs +0 -1
- package/dist/esm/core/utils/setObjectProperty.d.mts +0 -11
- package/dist/esm/core/utils/setObjectProperty.mjs +0 -39
- /package/dist/cjs/api/types/{AssetsWithIncludesResponse.js → AuditLogsWithIncludesResponse.js} +0 -0
- /package/dist/cjs/api/types/{AuditLogsResponse.js → FileAssetsWithIncludesResponse.js} +0 -0
- /package/dist/cjs/api/types/{UserRolesResponse.js → FolderAssetsWithIncludesResponse.js} +0 -0
- /package/dist/esm/api/types/{AssetsWithIncludesResponse.mjs → AuditLogsWithIncludesResponse.mjs} +0 -0
- /package/dist/esm/api/types/{AuditLogsResponse.mjs → FileAssetsWithIncludesResponse.mjs} +0 -0
- /package/dist/esm/api/types/{UserRolesResponse.mjs → FolderAssetsWithIncludesResponse.mjs} +0 -0
|
@@ -198,7 +198,7 @@ export class Shares {
|
|
|
198
198
|
* access: "public",
|
|
199
199
|
* description: "A descriptive summary of the share",
|
|
200
200
|
* downloading_enabled: true,
|
|
201
|
-
* expiration: "2026-01-
|
|
201
|
+
* expiration: "2026-01-29T19:41:37Z",
|
|
202
202
|
* name: "Share Name",
|
|
203
203
|
* passphrase: "as!dfj39sd(*"
|
|
204
204
|
* }
|
|
@@ -290,88 +290,75 @@ export class Shares {
|
|
|
290
290
|
* include_total_count: false
|
|
291
291
|
* })
|
|
292
292
|
*/
|
|
293
|
-
listReviewers(
|
|
293
|
+
listReviewers(accountId, shareId, request = {}, requestOptions) {
|
|
294
|
+
return core.HttpResponsePromise.fromPromise(this.__listReviewers(accountId, shareId, request, requestOptions));
|
|
295
|
+
}
|
|
296
|
+
__listReviewers(accountId_1, shareId_1) {
|
|
294
297
|
return __awaiter(this, arguments, void 0, function* (accountId, shareId, request = {}, requestOptions) {
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
throw new Frameio.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
338
|
-
case 429:
|
|
339
|
-
throw new Frameio.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
340
|
-
default:
|
|
341
|
-
throw new errors.FrameioError({
|
|
342
|
-
statusCode: _response.error.statusCode,
|
|
343
|
-
body: _response.error.body,
|
|
344
|
-
rawResponse: _response.rawResponse,
|
|
345
|
-
});
|
|
346
|
-
}
|
|
347
|
-
}
|
|
348
|
-
switch (_response.error.reason) {
|
|
349
|
-
case "non-json":
|
|
298
|
+
var _a, _b, _c;
|
|
299
|
+
const { after, page_size: pageSize, include_total_count: includeTotalCount } = request;
|
|
300
|
+
const _queryParams = {};
|
|
301
|
+
if (after != null) {
|
|
302
|
+
_queryParams["after"] = after;
|
|
303
|
+
}
|
|
304
|
+
if (pageSize != null) {
|
|
305
|
+
_queryParams["page_size"] = pageSize.toString();
|
|
306
|
+
}
|
|
307
|
+
if (includeTotalCount != null) {
|
|
308
|
+
_queryParams["include_total_count"] = includeTotalCount.toString();
|
|
309
|
+
}
|
|
310
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
311
|
+
const _response = yield core.fetcher({
|
|
312
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FrameioEnvironment.Default, `v4/accounts/${encodeURIComponent(accountId)}/shares/${encodeURIComponent(shareId)}/reviewers`),
|
|
313
|
+
method: "GET",
|
|
314
|
+
headers: _headers,
|
|
315
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
316
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
317
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
318
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
319
|
+
});
|
|
320
|
+
if (_response.ok) {
|
|
321
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
322
|
+
}
|
|
323
|
+
if (_response.error.reason === "status-code") {
|
|
324
|
+
switch (_response.error.statusCode) {
|
|
325
|
+
case 400:
|
|
326
|
+
throw new Frameio.BadRequestError(_response.error.body, _response.rawResponse);
|
|
327
|
+
case 401:
|
|
328
|
+
throw new Frameio.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
329
|
+
case 403:
|
|
330
|
+
throw new Frameio.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
331
|
+
case 404:
|
|
332
|
+
throw new Frameio.NotFoundError(_response.error.body, _response.rawResponse);
|
|
333
|
+
case 409:
|
|
334
|
+
throw new Frameio.ConflictError(_response.error.body, _response.rawResponse);
|
|
335
|
+
case 422:
|
|
336
|
+
throw new Frameio.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
337
|
+
case 429:
|
|
338
|
+
throw new Frameio.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
339
|
+
default:
|
|
350
340
|
throw new errors.FrameioError({
|
|
351
341
|
statusCode: _response.error.statusCode,
|
|
352
|
-
body: _response.error.
|
|
353
|
-
rawResponse: _response.rawResponse,
|
|
354
|
-
});
|
|
355
|
-
case "timeout":
|
|
356
|
-
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/shares/{share_id}/reviewers.");
|
|
357
|
-
case "unknown":
|
|
358
|
-
throw new errors.FrameioError({
|
|
359
|
-
message: _response.error.errorMessage,
|
|
342
|
+
body: _response.error.body,
|
|
360
343
|
rawResponse: _response.rawResponse,
|
|
361
344
|
});
|
|
362
345
|
}
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
346
|
+
}
|
|
347
|
+
switch (_response.error.reason) {
|
|
348
|
+
case "non-json":
|
|
349
|
+
throw new errors.FrameioError({
|
|
350
|
+
statusCode: _response.error.statusCode,
|
|
351
|
+
body: _response.error.rawBody,
|
|
352
|
+
rawResponse: _response.rawResponse,
|
|
353
|
+
});
|
|
354
|
+
case "timeout":
|
|
355
|
+
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/shares/{share_id}/reviewers.");
|
|
356
|
+
case "unknown":
|
|
357
|
+
throw new errors.FrameioError({
|
|
358
|
+
message: _response.error.errorMessage,
|
|
359
|
+
rawResponse: _response.rawResponse,
|
|
360
|
+
});
|
|
361
|
+
}
|
|
375
362
|
});
|
|
376
363
|
}
|
|
377
364
|
/**
|
|
@@ -657,7 +644,7 @@ export class Shares {
|
|
|
657
644
|
* @example
|
|
658
645
|
* await client.shares.addAsset("b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", "b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", {
|
|
659
646
|
* data: {
|
|
660
|
-
* asset_id: "
|
|
647
|
+
* asset_id: "26a44993-9abd-49bb-8e39-2f44b4a72f62"
|
|
661
648
|
* }
|
|
662
649
|
* })
|
|
663
650
|
*/
|
|
@@ -747,85 +734,75 @@ export class Shares {
|
|
|
747
734
|
* include_total_count: false
|
|
748
735
|
* })
|
|
749
736
|
*/
|
|
750
|
-
index(
|
|
737
|
+
index(accountId, projectId, request = {}, requestOptions) {
|
|
738
|
+
return core.HttpResponsePromise.fromPromise(this.__index(accountId, projectId, request, requestOptions));
|
|
739
|
+
}
|
|
740
|
+
__index(accountId_1, projectId_1) {
|
|
751
741
|
return __awaiter(this, arguments, void 0, function* (accountId, projectId, request = {}, requestOptions) {
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
default:
|
|
795
|
-
throw new errors.FrameioError({
|
|
796
|
-
statusCode: _response.error.statusCode,
|
|
797
|
-
body: _response.error.body,
|
|
798
|
-
rawResponse: _response.rawResponse,
|
|
799
|
-
});
|
|
800
|
-
}
|
|
801
|
-
}
|
|
802
|
-
switch (_response.error.reason) {
|
|
803
|
-
case "non-json":
|
|
742
|
+
var _a, _b, _c;
|
|
743
|
+
const { after, page_size: pageSize, include_total_count: includeTotalCount } = request;
|
|
744
|
+
const _queryParams = {};
|
|
745
|
+
if (after != null) {
|
|
746
|
+
_queryParams["after"] = after;
|
|
747
|
+
}
|
|
748
|
+
if (pageSize != null) {
|
|
749
|
+
_queryParams["page_size"] = pageSize.toString();
|
|
750
|
+
}
|
|
751
|
+
if (includeTotalCount != null) {
|
|
752
|
+
_queryParams["include_total_count"] = includeTotalCount.toString();
|
|
753
|
+
}
|
|
754
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
755
|
+
const _response = yield core.fetcher({
|
|
756
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FrameioEnvironment.Default, `v4/accounts/${encodeURIComponent(accountId)}/projects/${encodeURIComponent(projectId)}/shares`),
|
|
757
|
+
method: "GET",
|
|
758
|
+
headers: _headers,
|
|
759
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
760
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
761
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
762
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
763
|
+
});
|
|
764
|
+
if (_response.ok) {
|
|
765
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
766
|
+
}
|
|
767
|
+
if (_response.error.reason === "status-code") {
|
|
768
|
+
switch (_response.error.statusCode) {
|
|
769
|
+
case 400:
|
|
770
|
+
throw new Frameio.BadRequestError(_response.error.body, _response.rawResponse);
|
|
771
|
+
case 401:
|
|
772
|
+
throw new Frameio.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
773
|
+
case 403:
|
|
774
|
+
throw new Frameio.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
775
|
+
case 404:
|
|
776
|
+
throw new Frameio.NotFoundError(_response.error.body, _response.rawResponse);
|
|
777
|
+
case 409:
|
|
778
|
+
throw new Frameio.ConflictError(_response.error.body, _response.rawResponse);
|
|
779
|
+
case 422:
|
|
780
|
+
throw new Frameio.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
781
|
+
case 429:
|
|
782
|
+
throw new Frameio.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
783
|
+
default:
|
|
804
784
|
throw new errors.FrameioError({
|
|
805
785
|
statusCode: _response.error.statusCode,
|
|
806
|
-
body: _response.error.
|
|
807
|
-
rawResponse: _response.rawResponse,
|
|
808
|
-
});
|
|
809
|
-
case "timeout":
|
|
810
|
-
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/projects/{project_id}/shares.");
|
|
811
|
-
case "unknown":
|
|
812
|
-
throw new errors.FrameioError({
|
|
813
|
-
message: _response.error.errorMessage,
|
|
786
|
+
body: _response.error.body,
|
|
814
787
|
rawResponse: _response.rawResponse,
|
|
815
788
|
});
|
|
816
789
|
}
|
|
817
|
-
}
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
790
|
+
}
|
|
791
|
+
switch (_response.error.reason) {
|
|
792
|
+
case "non-json":
|
|
793
|
+
throw new errors.FrameioError({
|
|
794
|
+
statusCode: _response.error.statusCode,
|
|
795
|
+
body: _response.error.rawBody,
|
|
796
|
+
rawResponse: _response.rawResponse,
|
|
797
|
+
});
|
|
798
|
+
case "timeout":
|
|
799
|
+
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/projects/{project_id}/shares.");
|
|
800
|
+
case "unknown":
|
|
801
|
+
throw new errors.FrameioError({
|
|
802
|
+
message: _response.error.errorMessage,
|
|
803
|
+
rawResponse: _response.rawResponse,
|
|
804
|
+
});
|
|
805
|
+
}
|
|
829
806
|
});
|
|
830
807
|
}
|
|
831
808
|
/**
|
|
@@ -849,9 +826,9 @@ export class Shares {
|
|
|
849
826
|
* data: {
|
|
850
827
|
* type: "asset",
|
|
851
828
|
* access: "public",
|
|
852
|
-
* asset_ids: ["
|
|
829
|
+
* asset_ids: ["b68f4112-23fe-475e-9927-c0405331266b", "888a368c-06b2-47f8-b3b1-09ce71d37e6b"],
|
|
853
830
|
* downloading_enabled: true,
|
|
854
|
-
* expiration: "2026-01-
|
|
831
|
+
* expiration: "2026-01-29T19:41:37Z",
|
|
855
832
|
* name: "Share Name",
|
|
856
833
|
* passphrase: "as!dfj39sd(*"
|
|
857
834
|
* }
|
|
@@ -5,9 +5,9 @@ import * as Frameio from "../../../../index.mjs";
|
|
|
5
5
|
* data: {
|
|
6
6
|
* type: "asset",
|
|
7
7
|
* access: "public",
|
|
8
|
-
* asset_ids: ["
|
|
8
|
+
* asset_ids: ["b68f4112-23fe-475e-9927-c0405331266b", "888a368c-06b2-47f8-b3b1-09ce71d37e6b"],
|
|
9
9
|
* downloading_enabled: true,
|
|
10
|
-
* expiration: "2026-01-
|
|
10
|
+
* expiration: "2026-01-29T19:41:37Z",
|
|
11
11
|
* name: "Share Name",
|
|
12
12
|
* passphrase: "as!dfj39sd(*"
|
|
13
13
|
* }
|
|
@@ -65,7 +65,7 @@ export declare class VersionStacks {
|
|
|
65
65
|
* include_total_count: false
|
|
66
66
|
* })
|
|
67
67
|
*/
|
|
68
|
-
index(accountId: Frameio.Uuid, versionStackId: Frameio.Uuid, request?: Frameio.VersionStacksIndexRequest, requestOptions?: VersionStacks.RequestOptions): core.HttpResponsePromise<Frameio.
|
|
68
|
+
index(accountId: Frameio.Uuid, versionStackId: Frameio.Uuid, request?: Frameio.VersionStacksIndexRequest, requestOptions?: VersionStacks.RequestOptions): core.HttpResponsePromise<Frameio.VersionStackAssetsWithIncludesResponse>;
|
|
69
69
|
private __index;
|
|
70
70
|
/**
|
|
71
71
|
* Show version stack details. <br>Rate Limits: 100 calls per 1.00 minute(s) per account_user
|
|
@@ -161,7 +161,7 @@ export declare class VersionStacks {
|
|
|
161
161
|
* @example
|
|
162
162
|
* await client.versionStacks.create("b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", "b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", {
|
|
163
163
|
* data: {
|
|
164
|
-
* file_ids: ["
|
|
164
|
+
* file_ids: ["6ba6eaa7-1079-46ab-8448-0f9e9c7075e2", "2ea8d129-5381-48e0-852f-be35f90435a9"]
|
|
165
165
|
* }
|
|
166
166
|
* })
|
|
167
167
|
*/
|
|
@@ -98,7 +98,10 @@ export class VersionStacks {
|
|
|
98
98
|
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
99
99
|
});
|
|
100
100
|
if (_response.ok) {
|
|
101
|
-
return {
|
|
101
|
+
return {
|
|
102
|
+
data: _response.body,
|
|
103
|
+
rawResponse: _response.rawResponse,
|
|
104
|
+
};
|
|
102
105
|
}
|
|
103
106
|
if (_response.error.reason === "status-code") {
|
|
104
107
|
switch (_response.error.statusCode) {
|
|
@@ -442,7 +445,7 @@ export class VersionStacks {
|
|
|
442
445
|
* @example
|
|
443
446
|
* await client.versionStacks.create("b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", "b2702c44-c6da-4bb6-8bbd-be6e547ccf1b", {
|
|
444
447
|
* data: {
|
|
445
|
-
* file_ids: ["
|
|
448
|
+
* file_ids: ["6ba6eaa7-1079-46ab-8448-0f9e9c7075e2", "2ea8d129-5381-48e0-852f-be35f90435a9"]
|
|
446
449
|
* }
|
|
447
450
|
* })
|
|
448
451
|
*/
|
|
@@ -53,7 +53,8 @@ export declare class Webhooks {
|
|
|
53
53
|
* include_total_count: false
|
|
54
54
|
* })
|
|
55
55
|
*/
|
|
56
|
-
index(accountId: Frameio.Uuid, workspaceId: Frameio.Uuid, request?: Frameio.WebhooksIndexRequest, requestOptions?: Webhooks.RequestOptions):
|
|
56
|
+
index(accountId: Frameio.Uuid, workspaceId: Frameio.Uuid, request?: Frameio.WebhooksIndexRequest, requestOptions?: Webhooks.RequestOptions): core.HttpResponsePromise<Frameio.WebhooksWithIncludesResponse>;
|
|
57
|
+
private __index;
|
|
57
58
|
/**
|
|
58
59
|
* Creates a single webhook with secret.<br/><br/>Valid events:<p><code>
|
|
59
60
|
* file.created, file.deleted, file.ready, file.updated, file.upload.completed, file.versioned, file.copied, folder.created, folder.deleted, folder.updated, folder.copied, comment.completed, comment.created, comment.deleted, comment.uncompleted, comment.updated, customfield.created, customfield.updated, customfield.deleted, metadata.value.updated, project.created, project.deleted, project.updated, collection.created, collection.updated, collection.deleted, share.created, share.updated, share.deleted, share.viewed
|
|
@@ -44,91 +44,78 @@ export class Webhooks {
|
|
|
44
44
|
* include_total_count: false
|
|
45
45
|
* })
|
|
46
46
|
*/
|
|
47
|
-
index(
|
|
47
|
+
index(accountId, workspaceId, request = {}, requestOptions) {
|
|
48
|
+
return core.HttpResponsePromise.fromPromise(this.__index(accountId, workspaceId, request, requestOptions));
|
|
49
|
+
}
|
|
50
|
+
__index(accountId_1, workspaceId_1) {
|
|
48
51
|
return __awaiter(this, arguments, void 0, function* (accountId, workspaceId, request = {}, requestOptions) {
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
throw new Frameio.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
95
|
-
case 429:
|
|
96
|
-
throw new Frameio.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
97
|
-
default:
|
|
98
|
-
throw new errors.FrameioError({
|
|
99
|
-
statusCode: _response.error.statusCode,
|
|
100
|
-
body: _response.error.body,
|
|
101
|
-
rawResponse: _response.rawResponse,
|
|
102
|
-
});
|
|
103
|
-
}
|
|
104
|
-
}
|
|
105
|
-
switch (_response.error.reason) {
|
|
106
|
-
case "non-json":
|
|
52
|
+
var _a, _b, _c;
|
|
53
|
+
const { include, after, page_size: pageSize, include_total_count: includeTotalCount } = request;
|
|
54
|
+
const _queryParams = {};
|
|
55
|
+
if (include != null) {
|
|
56
|
+
_queryParams["include"] = include;
|
|
57
|
+
}
|
|
58
|
+
if (after != null) {
|
|
59
|
+
_queryParams["after"] = after;
|
|
60
|
+
}
|
|
61
|
+
if (pageSize != null) {
|
|
62
|
+
_queryParams["page_size"] = pageSize.toString();
|
|
63
|
+
}
|
|
64
|
+
if (includeTotalCount != null) {
|
|
65
|
+
_queryParams["include_total_count"] = includeTotalCount.toString();
|
|
66
|
+
}
|
|
67
|
+
let _headers = mergeHeaders((_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ Authorization: yield this._getAuthorizationHeader() }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
68
|
+
const _response = yield core.fetcher({
|
|
69
|
+
url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.FrameioEnvironment.Default, `v4/accounts/${encodeURIComponent(accountId)}/workspaces/${encodeURIComponent(workspaceId)}/webhooks`),
|
|
70
|
+
method: "GET",
|
|
71
|
+
headers: _headers,
|
|
72
|
+
queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
|
|
73
|
+
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
74
|
+
maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
|
|
75
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
76
|
+
});
|
|
77
|
+
if (_response.ok) {
|
|
78
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
79
|
+
}
|
|
80
|
+
if (_response.error.reason === "status-code") {
|
|
81
|
+
switch (_response.error.statusCode) {
|
|
82
|
+
case 400:
|
|
83
|
+
throw new Frameio.BadRequestError(_response.error.body, _response.rawResponse);
|
|
84
|
+
case 401:
|
|
85
|
+
throw new Frameio.UnauthorizedError(_response.error.body, _response.rawResponse);
|
|
86
|
+
case 403:
|
|
87
|
+
throw new Frameio.ForbiddenError(_response.error.body, _response.rawResponse);
|
|
88
|
+
case 404:
|
|
89
|
+
throw new Frameio.NotFoundError(_response.error.body, _response.rawResponse);
|
|
90
|
+
case 409:
|
|
91
|
+
throw new Frameio.ConflictError(_response.error.body, _response.rawResponse);
|
|
92
|
+
case 422:
|
|
93
|
+
throw new Frameio.UnprocessableEntityError(_response.error.body, _response.rawResponse);
|
|
94
|
+
case 429:
|
|
95
|
+
throw new Frameio.TooManyRequestsError(_response.error.body, _response.rawResponse);
|
|
96
|
+
default:
|
|
107
97
|
throw new errors.FrameioError({
|
|
108
98
|
statusCode: _response.error.statusCode,
|
|
109
|
-
body: _response.error.
|
|
110
|
-
rawResponse: _response.rawResponse,
|
|
111
|
-
});
|
|
112
|
-
case "timeout":
|
|
113
|
-
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/workspaces/{workspace_id}/webhooks.");
|
|
114
|
-
case "unknown":
|
|
115
|
-
throw new errors.FrameioError({
|
|
116
|
-
message: _response.error.errorMessage,
|
|
99
|
+
body: _response.error.body,
|
|
117
100
|
rawResponse: _response.rawResponse,
|
|
118
101
|
});
|
|
119
102
|
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
103
|
+
}
|
|
104
|
+
switch (_response.error.reason) {
|
|
105
|
+
case "non-json":
|
|
106
|
+
throw new errors.FrameioError({
|
|
107
|
+
statusCode: _response.error.statusCode,
|
|
108
|
+
body: _response.error.rawBody,
|
|
109
|
+
rawResponse: _response.rawResponse,
|
|
110
|
+
});
|
|
111
|
+
case "timeout":
|
|
112
|
+
throw new errors.FrameioTimeoutError("Timeout exceeded when calling GET /v4/accounts/{account_id}/workspaces/{workspace_id}/webhooks.");
|
|
113
|
+
case "unknown":
|
|
114
|
+
throw new errors.FrameioError({
|
|
115
|
+
message: _response.error.errorMessage,
|
|
116
|
+
rawResponse: _response.rawResponse,
|
|
117
|
+
});
|
|
118
|
+
}
|
|
132
119
|
});
|
|
133
120
|
}
|
|
134
121
|
/**
|
|
@@ -53,7 +53,8 @@ export declare class WorkspacePermissions {
|
|
|
53
53
|
* include_total_count: false
|
|
54
54
|
* })
|
|
55
55
|
*/
|
|
56
|
-
index(accountId: Frameio.Uuid, workspaceId: Frameio.Uuid, request?: Frameio.WorkspacePermissionsIndexRequest, requestOptions?: WorkspacePermissions.RequestOptions):
|
|
56
|
+
index(accountId: Frameio.Uuid, workspaceId: Frameio.Uuid, request?: Frameio.WorkspacePermissionsIndexRequest, requestOptions?: WorkspacePermissions.RequestOptions): core.HttpResponsePromise<Frameio.WorkspaceUserRolesResponse>;
|
|
57
|
+
private __index;
|
|
57
58
|
/**
|
|
58
59
|
* Remove a user from a given workspace. <br>Rate Limits: 60 calls per 1.00 minute(s) per account_user
|
|
59
60
|
*
|