@cloudpdf/sdk 3.0.0-next.1 → 3.0.0-next.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 +23 -46
- package/dist/cjs/BaseClient.js +2 -2
- package/dist/cjs/Client.d.ts +3 -0
- package/dist/cjs/Client.js +9 -4
- package/dist/cjs/CloudPDFClient.d.ts +20 -0
- package/dist/cjs/CloudPDFClient.js +39 -0
- package/dist/cjs/api/errors/ConflictError.d.ts +7 -0
- package/dist/cjs/api/errors/ConflictError.js +54 -0
- package/dist/cjs/api/errors/GoneError.d.ts +7 -0
- package/dist/cjs/api/errors/GoneError.js +54 -0
- package/dist/cjs/api/errors/UnprocessableEntityError.d.ts +7 -0
- package/dist/cjs/api/errors/UnprocessableEntityError.js +54 -0
- package/dist/cjs/api/errors/index.d.ts +3 -0
- package/dist/cjs/api/errors/index.js +3 -0
- package/dist/cjs/api/resources/documents/client/Client.d.ts +14 -5
- package/dist/cjs/api/resources/documents/client/Client.js +26 -14
- package/dist/cjs/api/resources/documents/client/requests/DocumentsInitRequest.d.ts +7 -0
- package/dist/cjs/api/resources/documents/client/requests/DocumentsInitRequest.js +5 -0
- package/dist/cjs/api/resources/documents/client/requests/UploadProxyDocumentsRequest.d.ts +14 -0
- package/dist/cjs/api/resources/documents/client/requests/index.d.ts +1 -0
- package/dist/cjs/api/resources/index.d.ts +2 -0
- package/dist/cjs/api/resources/index.js +3 -1
- package/dist/cjs/api/resources/shares/client/Client.d.ts +119 -0
- package/dist/cjs/api/resources/shares/client/Client.js +422 -0
- package/dist/cjs/api/resources/shares/client/index.d.ts +1 -0
- package/dist/cjs/api/resources/shares/client/index.js +17 -0
- package/dist/cjs/api/resources/shares/client/requests/DeleteSharesRequest.d.ts +11 -0
- package/dist/cjs/api/resources/shares/client/requests/GetSharesRequest.d.ts +11 -0
- package/dist/cjs/api/resources/shares/client/requests/GetSharesRequest.js +3 -0
- package/dist/cjs/api/resources/shares/client/requests/ListSharesRequest.d.ts +12 -0
- package/dist/cjs/api/resources/shares/client/requests/ListSharesRequest.js +3 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesCreateRequest.d.ts +18 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesCreateRequest.js +3 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesExchangeRequest.d.ts +10 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesExchangeRequest.js +3 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesUpdateRequest.d.ts +17 -0
- package/dist/cjs/api/resources/shares/client/requests/SharesUpdateRequest.js +3 -0
- package/dist/cjs/api/resources/shares/client/requests/index.d.ts +6 -0
- package/dist/cjs/api/resources/shares/client/requests/index.js +2 -0
- package/dist/cjs/api/resources/shares/exports.d.ts +2 -0
- package/dist/cjs/api/resources/shares/exports.js +21 -0
- package/dist/cjs/api/resources/shares/index.d.ts +1 -0
- package/dist/cjs/api/resources/shares/index.js +17 -0
- package/dist/cjs/api/resources/tenants/client/Client.d.ts +50 -0
- package/dist/cjs/api/resources/tenants/client/Client.js +181 -0
- package/dist/cjs/api/resources/tenants/client/requests/ResumeTenantsRequest.d.ts +9 -0
- package/dist/cjs/api/resources/tenants/client/requests/ResumeTenantsRequest.js +3 -0
- package/dist/cjs/api/resources/tenants/client/requests/TenantsSuspendRequest.d.ts +10 -0
- package/dist/cjs/api/resources/tenants/client/requests/TenantsSuspendRequest.js +3 -0
- package/dist/cjs/api/resources/tenants/client/requests/UsageTenantsRequest.d.ts +10 -0
- package/dist/cjs/api/resources/tenants/client/requests/UsageTenantsRequest.js +3 -0
- package/dist/cjs/api/resources/tenants/client/requests/index.d.ts +3 -0
- package/dist/cjs/api/types/DocumentsInit200ResponseCreatedUpload.d.ts +3 -3
- package/dist/cjs/api/types/DocumentsInit200ResponseResumedUpload.d.ts +3 -3
- package/dist/cjs/api/types/DocumentsUploadProxy200Response.d.ts +3 -0
- package/dist/cjs/api/types/DocumentsUploadProxy200Response.js +3 -0
- package/dist/cjs/api/types/DocumentsUploadProxy400Response.d.ts +9 -0
- package/dist/cjs/api/types/DocumentsUploadProxy400Response.js +3 -0
- package/dist/cjs/api/types/DocumentsUploadProxy409Response.d.ts +9 -0
- package/dist/cjs/api/types/DocumentsUploadProxy409Response.js +3 -0
- package/dist/cjs/api/types/SharesCreate200Response.d.ts +22 -0
- package/dist/cjs/api/types/SharesCreate200Response.js +3 -0
- package/dist/cjs/api/types/SharesCreate400Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesCreate400Response.js +3 -0
- package/dist/cjs/api/types/SharesCreate403Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesCreate403Response.js +3 -0
- package/dist/cjs/api/types/SharesCreate404Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesCreate404Response.js +3 -0
- package/dist/cjs/api/types/SharesDeleteResponse.d.ts +9 -0
- package/dist/cjs/api/types/SharesDeleteResponse.js +3 -0
- package/dist/cjs/api/types/SharesExchange200Response.d.ts +6 -0
- package/dist/cjs/api/types/SharesExchange200Response.js +3 -0
- package/dist/cjs/api/types/SharesExchange400Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesExchange400Response.js +3 -0
- package/dist/cjs/api/types/SharesExchange403Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesExchange403Response.js +3 -0
- package/dist/cjs/api/types/SharesExchange404Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesExchange404Response.js +3 -0
- package/dist/cjs/api/types/SharesExchange410Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesExchange410Response.js +3 -0
- package/dist/cjs/api/types/SharesExchange422Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesExchange422Response.js +3 -0
- package/dist/cjs/api/types/SharesGet200Response.d.ts +22 -0
- package/dist/cjs/api/types/SharesGet200Response.js +3 -0
- package/dist/cjs/api/types/SharesGet404Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesGet404Response.js +3 -0
- package/dist/cjs/api/types/SharesList200Response.d.ts +26 -0
- package/dist/cjs/api/types/SharesList200Response.js +3 -0
- package/dist/cjs/api/types/SharesList400Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesList400Response.js +3 -0
- package/dist/cjs/api/types/SharesUpdate200Response.d.ts +22 -0
- package/dist/cjs/api/types/SharesUpdate200Response.js +3 -0
- package/dist/cjs/api/types/SharesUpdate400Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesUpdate400Response.js +3 -0
- package/dist/cjs/api/types/SharesUpdate404Response.d.ts +9 -0
- package/dist/cjs/api/types/SharesUpdate404Response.js +3 -0
- package/dist/cjs/api/types/TenantsCreate200Response.d.ts +8 -0
- package/dist/cjs/api/types/TenantsCreate200Response.js +11 -0
- package/dist/cjs/api/types/TenantsGet200Response.d.ts +8 -0
- package/dist/cjs/api/types/TenantsGet200Response.js +11 -0
- package/dist/cjs/api/types/TenantsList200Response.d.ts +8 -0
- package/dist/cjs/api/types/TenantsList200Response.js +14 -0
- package/dist/cjs/api/types/TenantsResumeResponse.d.ts +9 -0
- package/dist/cjs/api/types/TenantsResumeResponse.js +3 -0
- package/dist/cjs/api/types/TenantsSuspendResponse.d.ts +9 -0
- package/dist/cjs/api/types/TenantsSuspendResponse.js +3 -0
- package/dist/cjs/api/types/TenantsUsage200Response.d.ts +13 -0
- package/dist/cjs/api/types/TenantsUsage200Response.js +3 -0
- package/dist/cjs/api/types/TenantsUsage400Response.d.ts +9 -0
- package/dist/cjs/api/types/TenantsUsage400Response.js +3 -0
- package/dist/cjs/api/types/TenantsUsage404Response.d.ts +9 -0
- package/dist/cjs/api/types/TenantsUsage404Response.js +3 -0
- package/dist/cjs/api/types/TokensIssueRequest.d.ts +2 -1
- package/dist/cjs/api/types/index.d.ts +26 -2
- package/dist/cjs/api/types/index.js +26 -2
- package/dist/cjs/auth/BearerAuthProvider.d.ts +1 -1
- package/dist/cjs/core/form-data-utils/FormDataWrapper.d.ts +15 -0
- package/dist/cjs/core/form-data-utils/FormDataWrapper.js +188 -0
- package/dist/cjs/core/form-data-utils/encodeAsFormParameter.d.ts +1 -0
- package/dist/cjs/core/form-data-utils/encodeAsFormParameter.js +12 -0
- package/dist/cjs/core/form-data-utils/index.d.ts +2 -0
- package/dist/cjs/core/form-data-utils/index.js +20 -0
- package/dist/cjs/core/index.d.ts +1 -0
- package/dist/cjs/core/index.js +1 -0
- package/dist/cjs/index.d.ts +3 -1
- package/dist/cjs/index.js +5 -2
- package/dist/cjs/uploads/Uploads.d.ts +7 -0
- package/dist/cjs/uploads/Uploads.js +78 -0
- package/dist/cjs/uploads/index.d.ts +2 -0
- package/dist/cjs/uploads/index.js +5 -0
- package/dist/cjs/uploads/source.d.ts +10 -0
- package/dist/cjs/uploads/source.js +155 -0
- package/dist/cjs/uploads/types.d.ts +46 -0
- package/dist/cjs/uploads/types.js +2 -0
- package/dist/cjs/version.d.ts +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/esm/BaseClient.mjs +2 -2
- package/dist/esm/Client.d.mts +3 -0
- package/dist/esm/Client.mjs +5 -0
- package/dist/esm/CloudPDFClient.d.mts +20 -0
- package/dist/esm/CloudPDFClient.mjs +35 -0
- package/dist/esm/api/errors/ConflictError.d.mts +7 -0
- package/dist/esm/api/errors/ConflictError.mjs +17 -0
- package/dist/esm/api/errors/GoneError.d.mts +7 -0
- package/dist/esm/api/errors/GoneError.mjs +17 -0
- package/dist/esm/api/errors/UnprocessableEntityError.d.mts +7 -0
- package/dist/esm/api/errors/UnprocessableEntityError.mjs +17 -0
- package/dist/esm/api/errors/index.d.mts +3 -0
- package/dist/esm/api/errors/index.mjs +3 -0
- package/dist/esm/api/resources/documents/client/Client.d.mts +14 -5
- package/dist/esm/api/resources/documents/client/Client.mjs +27 -15
- package/dist/esm/api/resources/documents/client/requests/DocumentsInitRequest.d.mts +7 -0
- package/dist/esm/api/resources/documents/client/requests/DocumentsInitRequest.mjs +5 -0
- package/dist/esm/api/resources/documents/client/requests/UploadProxyDocumentsRequest.d.mts +14 -0
- package/dist/esm/api/resources/documents/client/requests/index.d.mts +1 -0
- package/dist/esm/api/resources/index.d.mts +2 -0
- package/dist/esm/api/resources/index.mjs +2 -0
- package/dist/esm/api/resources/shares/client/Client.d.mts +119 -0
- package/dist/esm/api/resources/shares/client/Client.mjs +385 -0
- package/dist/esm/api/resources/shares/client/index.d.mts +1 -0
- package/dist/esm/api/resources/shares/client/index.mjs +1 -0
- package/dist/esm/api/resources/shares/client/requests/DeleteSharesRequest.d.mts +11 -0
- package/dist/esm/api/resources/shares/client/requests/GetSharesRequest.d.mts +11 -0
- package/dist/esm/api/resources/shares/client/requests/GetSharesRequest.mjs +2 -0
- package/dist/esm/api/resources/shares/client/requests/ListSharesRequest.d.mts +12 -0
- package/dist/esm/api/resources/shares/client/requests/ListSharesRequest.mjs +2 -0
- package/dist/esm/api/resources/shares/client/requests/SharesCreateRequest.d.mts +18 -0
- package/dist/esm/api/resources/shares/client/requests/SharesCreateRequest.mjs +2 -0
- package/dist/esm/api/resources/shares/client/requests/SharesExchangeRequest.d.mts +10 -0
- package/dist/esm/api/resources/shares/client/requests/SharesExchangeRequest.mjs +2 -0
- package/dist/esm/api/resources/shares/client/requests/SharesUpdateRequest.d.mts +17 -0
- package/dist/esm/api/resources/shares/client/requests/SharesUpdateRequest.mjs +2 -0
- package/dist/esm/api/resources/shares/client/requests/index.d.mts +6 -0
- package/dist/esm/api/resources/shares/client/requests/index.mjs +1 -0
- package/dist/esm/api/resources/shares/exports.d.mts +2 -0
- package/dist/esm/api/resources/shares/exports.mjs +3 -0
- package/dist/esm/api/resources/shares/index.d.mts +1 -0
- package/dist/esm/api/resources/shares/index.mjs +1 -0
- package/dist/esm/api/resources/tenants/client/Client.d.mts +50 -0
- package/dist/esm/api/resources/tenants/client/Client.mjs +181 -0
- package/dist/esm/api/resources/tenants/client/requests/ResumeTenantsRequest.d.mts +9 -0
- package/dist/esm/api/resources/tenants/client/requests/ResumeTenantsRequest.mjs +2 -0
- package/dist/esm/api/resources/tenants/client/requests/TenantsSuspendRequest.d.mts +10 -0
- package/dist/esm/api/resources/tenants/client/requests/TenantsSuspendRequest.mjs +2 -0
- package/dist/esm/api/resources/tenants/client/requests/UsageTenantsRequest.d.mts +10 -0
- package/dist/esm/api/resources/tenants/client/requests/UsageTenantsRequest.mjs +2 -0
- package/dist/esm/api/resources/tenants/client/requests/index.d.mts +3 -0
- package/dist/esm/api/types/DocumentsInit200ResponseCreatedUpload.d.mts +3 -3
- package/dist/esm/api/types/DocumentsInit200ResponseResumedUpload.d.mts +3 -3
- package/dist/esm/api/types/DocumentsUploadProxy200Response.d.mts +3 -0
- package/dist/esm/api/types/DocumentsUploadProxy200Response.mjs +2 -0
- package/dist/esm/api/types/DocumentsUploadProxy400Response.d.mts +9 -0
- package/dist/esm/api/types/DocumentsUploadProxy400Response.mjs +2 -0
- package/dist/esm/api/types/DocumentsUploadProxy409Response.d.mts +9 -0
- package/dist/esm/api/types/DocumentsUploadProxy409Response.mjs +2 -0
- package/dist/esm/api/types/SharesCreate200Response.d.mts +22 -0
- package/dist/esm/api/types/SharesCreate200Response.mjs +2 -0
- package/dist/esm/api/types/SharesCreate400Response.d.mts +9 -0
- package/dist/esm/api/types/SharesCreate400Response.mjs +2 -0
- package/dist/esm/api/types/SharesCreate403Response.d.mts +9 -0
- package/dist/esm/api/types/SharesCreate403Response.mjs +2 -0
- package/dist/esm/api/types/SharesCreate404Response.d.mts +9 -0
- package/dist/esm/api/types/SharesCreate404Response.mjs +2 -0
- package/dist/esm/api/types/SharesDeleteResponse.d.mts +9 -0
- package/dist/esm/api/types/SharesDeleteResponse.mjs +2 -0
- package/dist/esm/api/types/SharesExchange200Response.d.mts +6 -0
- package/dist/esm/api/types/SharesExchange200Response.mjs +2 -0
- package/dist/esm/api/types/SharesExchange400Response.d.mts +9 -0
- package/dist/esm/api/types/SharesExchange400Response.mjs +2 -0
- package/dist/esm/api/types/SharesExchange403Response.d.mts +9 -0
- package/dist/esm/api/types/SharesExchange403Response.mjs +2 -0
- package/dist/esm/api/types/SharesExchange404Response.d.mts +9 -0
- package/dist/esm/api/types/SharesExchange404Response.mjs +2 -0
- package/dist/esm/api/types/SharesExchange410Response.d.mts +9 -0
- package/dist/esm/api/types/SharesExchange410Response.mjs +2 -0
- package/dist/esm/api/types/SharesExchange422Response.d.mts +9 -0
- package/dist/esm/api/types/SharesExchange422Response.mjs +2 -0
- package/dist/esm/api/types/SharesGet200Response.d.mts +22 -0
- package/dist/esm/api/types/SharesGet200Response.mjs +2 -0
- package/dist/esm/api/types/SharesGet404Response.d.mts +9 -0
- package/dist/esm/api/types/SharesGet404Response.mjs +2 -0
- package/dist/esm/api/types/SharesList200Response.d.mts +26 -0
- package/dist/esm/api/types/SharesList200Response.mjs +2 -0
- package/dist/esm/api/types/SharesList400Response.d.mts +9 -0
- package/dist/esm/api/types/SharesList400Response.mjs +2 -0
- package/dist/esm/api/types/SharesUpdate200Response.d.mts +22 -0
- package/dist/esm/api/types/SharesUpdate200Response.mjs +2 -0
- package/dist/esm/api/types/SharesUpdate400Response.d.mts +9 -0
- package/dist/esm/api/types/SharesUpdate400Response.mjs +2 -0
- package/dist/esm/api/types/SharesUpdate404Response.d.mts +9 -0
- package/dist/esm/api/types/SharesUpdate404Response.mjs +2 -0
- package/dist/esm/api/types/TenantsCreate200Response.d.mts +8 -0
- package/dist/esm/api/types/TenantsCreate200Response.mjs +10 -1
- package/dist/esm/api/types/TenantsGet200Response.d.mts +8 -0
- package/dist/esm/api/types/TenantsGet200Response.mjs +10 -1
- package/dist/esm/api/types/TenantsList200Response.d.mts +8 -0
- package/dist/esm/api/types/TenantsList200Response.mjs +13 -1
- package/dist/esm/api/types/TenantsResumeResponse.d.mts +9 -0
- package/dist/esm/api/types/TenantsResumeResponse.mjs +2 -0
- package/dist/esm/api/types/TenantsSuspendResponse.d.mts +9 -0
- package/dist/esm/api/types/TenantsSuspendResponse.mjs +2 -0
- package/dist/esm/api/types/TenantsUsage200Response.d.mts +13 -0
- package/dist/esm/api/types/TenantsUsage200Response.mjs +2 -0
- package/dist/esm/api/types/TenantsUsage400Response.d.mts +9 -0
- package/dist/esm/api/types/TenantsUsage400Response.mjs +2 -0
- package/dist/esm/api/types/TenantsUsage404Response.d.mts +9 -0
- package/dist/esm/api/types/TenantsUsage404Response.mjs +2 -0
- package/dist/esm/api/types/TokensIssueRequest.d.mts +2 -1
- package/dist/esm/api/types/index.d.mts +26 -2
- package/dist/esm/api/types/index.mjs +26 -2
- package/dist/esm/auth/BearerAuthProvider.d.mts +1 -1
- package/dist/esm/core/form-data-utils/FormDataWrapper.d.mts +15 -0
- package/dist/esm/core/form-data-utils/FormDataWrapper.mjs +150 -0
- package/dist/esm/core/form-data-utils/encodeAsFormParameter.d.mts +1 -0
- package/dist/esm/core/form-data-utils/encodeAsFormParameter.mjs +9 -0
- package/dist/esm/core/form-data-utils/index.d.mts +2 -0
- package/dist/esm/core/form-data-utils/index.mjs +2 -0
- package/dist/esm/core/index.d.mts +1 -0
- package/dist/esm/core/index.mjs +1 -0
- package/dist/esm/index.d.mts +3 -1
- package/dist/esm/index.mjs +3 -1
- package/dist/esm/uploads/Uploads.d.mts +7 -0
- package/dist/esm/uploads/Uploads.mjs +74 -0
- package/dist/esm/uploads/index.d.mts +2 -0
- package/dist/esm/uploads/index.mjs +1 -0
- package/dist/esm/uploads/source.d.mts +10 -0
- package/dist/esm/uploads/source.mjs +119 -0
- package/dist/esm/uploads/types.d.mts +46 -0
- package/dist/esm/uploads/types.mjs +1 -0
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +188 -177
- package/reference.md +588 -0
- package/dist/cjs/api/types/DocumentsUploadDirect200Response.d.ts +0 -3
- package/dist/cjs/api/types/DocumentsUploadDirect400Response.d.ts +0 -9
- package/dist/esm/api/types/DocumentsUploadDirect200Response.d.mts +0 -3
- package/dist/esm/api/types/DocumentsUploadDirect400Response.d.mts +0 -9
- /package/dist/cjs/api/{types/DocumentsUploadDirect200Response.js → resources/documents/client/requests/UploadProxyDocumentsRequest.js} +0 -0
- /package/dist/cjs/api/{types/DocumentsUploadDirect400Response.js → resources/shares/client/requests/DeleteSharesRequest.js} +0 -0
- /package/dist/esm/api/{types/DocumentsUploadDirect200Response.mjs → resources/documents/client/requests/UploadProxyDocumentsRequest.mjs} +0 -0
- /package/dist/esm/api/{types/DocumentsUploadDirect400Response.mjs → resources/shares/client/requests/DeleteSharesRequest.mjs} +0 -0
|
@@ -8,6 +8,17 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
12
|
+
var t = {};
|
|
13
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
14
|
+
t[p] = s[p];
|
|
15
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
16
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
17
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
18
|
+
t[p[i]] = s[p[i]];
|
|
19
|
+
}
|
|
20
|
+
return t;
|
|
21
|
+
};
|
|
11
22
|
import { normalizeClientOptionsWithAuth } from "../../../../BaseClient.mjs";
|
|
12
23
|
import { mergeHeaders } from "../../../../core/headers.mjs";
|
|
13
24
|
import * as core from "../../../../core/index.mjs";
|
|
@@ -233,4 +244,174 @@ export class TenantsClient {
|
|
|
233
244
|
return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/v1/tenants/{tenantId}");
|
|
234
245
|
});
|
|
235
246
|
}
|
|
247
|
+
/**
|
|
248
|
+
* @param {CloudPDF.ResumeTenantsRequest} request
|
|
249
|
+
* @param {TenantsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
250
|
+
*
|
|
251
|
+
* @throws {@link CloudPDF.NotFoundError}
|
|
252
|
+
* @throws {@link errors.CloudPDFError}
|
|
253
|
+
* @throws {@link errors.CloudPDFTimeoutError}
|
|
254
|
+
*
|
|
255
|
+
* @example
|
|
256
|
+
* await client.tenants.resume({
|
|
257
|
+
* tenantId: "tenantId"
|
|
258
|
+
* })
|
|
259
|
+
*/
|
|
260
|
+
resume(request, requestOptions) {
|
|
261
|
+
return core.HttpResponsePromise.fromPromise(this.__resume(request, requestOptions));
|
|
262
|
+
}
|
|
263
|
+
__resume(request, requestOptions) {
|
|
264
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
265
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
266
|
+
const { tenantId } = request;
|
|
267
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
268
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
269
|
+
const _response = yield core.fetcher({
|
|
270
|
+
url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `v1/tenants/${core.url.encodePathParam(tenantId)}/resume`),
|
|
271
|
+
method: "POST",
|
|
272
|
+
headers: _headers,
|
|
273
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
274
|
+
timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
|
|
275
|
+
maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
|
|
276
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
277
|
+
fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
|
|
278
|
+
logging: this._options.logging,
|
|
279
|
+
});
|
|
280
|
+
if (_response.ok) {
|
|
281
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
282
|
+
}
|
|
283
|
+
if (_response.error.reason === "status-code") {
|
|
284
|
+
switch (_response.error.statusCode) {
|
|
285
|
+
case 404:
|
|
286
|
+
throw new CloudPDF.NotFoundError(_response.error.body, _response.rawResponse);
|
|
287
|
+
default:
|
|
288
|
+
throw new errors.CloudPDFError({
|
|
289
|
+
statusCode: _response.error.statusCode,
|
|
290
|
+
body: _response.error.body,
|
|
291
|
+
rawResponse: _response.rawResponse,
|
|
292
|
+
});
|
|
293
|
+
}
|
|
294
|
+
}
|
|
295
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/v1/tenants/{tenantId}/resume");
|
|
296
|
+
});
|
|
297
|
+
}
|
|
298
|
+
/**
|
|
299
|
+
* Instantly reversible with resume. The API token is exempt, so a suspended tenant can still be inspected, exported, resumed, or deleted.
|
|
300
|
+
*
|
|
301
|
+
* @param {CloudPDF.TenantsSuspendRequest} request
|
|
302
|
+
* @param {TenantsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
303
|
+
*
|
|
304
|
+
* @throws {@link CloudPDF.NotFoundError}
|
|
305
|
+
* @throws {@link errors.CloudPDFError}
|
|
306
|
+
* @throws {@link errors.CloudPDFTimeoutError}
|
|
307
|
+
*
|
|
308
|
+
* @example
|
|
309
|
+
* await client.tenants.suspend({
|
|
310
|
+
* tenantId: "tenantId"
|
|
311
|
+
* })
|
|
312
|
+
*/
|
|
313
|
+
suspend(request, requestOptions) {
|
|
314
|
+
return core.HttpResponsePromise.fromPromise(this.__suspend(request, requestOptions));
|
|
315
|
+
}
|
|
316
|
+
__suspend(request, requestOptions) {
|
|
317
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
318
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
319
|
+
const { tenantId } = request, _body = __rest(request, ["tenantId"]);
|
|
320
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
321
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
322
|
+
const _response = yield core.fetcher({
|
|
323
|
+
url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `v1/tenants/${core.url.encodePathParam(tenantId)}/suspend`),
|
|
324
|
+
method: "POST",
|
|
325
|
+
headers: _headers,
|
|
326
|
+
contentType: "application/json",
|
|
327
|
+
queryString: core.url.queryBuilder().mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams).build(),
|
|
328
|
+
requestType: "json",
|
|
329
|
+
body: mergeAdditionalBodyParameters(_body, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.additionalBodyParameters),
|
|
330
|
+
timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
|
|
331
|
+
maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
|
|
332
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
333
|
+
fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
|
|
334
|
+
logging: this._options.logging,
|
|
335
|
+
});
|
|
336
|
+
if (_response.ok) {
|
|
337
|
+
return { data: undefined, rawResponse: _response.rawResponse };
|
|
338
|
+
}
|
|
339
|
+
if (_response.error.reason === "status-code") {
|
|
340
|
+
switch (_response.error.statusCode) {
|
|
341
|
+
case 404:
|
|
342
|
+
throw new CloudPDF.NotFoundError(_response.error.body, _response.rawResponse);
|
|
343
|
+
default:
|
|
344
|
+
throw new errors.CloudPDFError({
|
|
345
|
+
statusCode: _response.error.statusCode,
|
|
346
|
+
body: _response.error.body,
|
|
347
|
+
rawResponse: _response.rawResponse,
|
|
348
|
+
});
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "POST", "/v1/tenants/{tenantId}/suspend");
|
|
352
|
+
});
|
|
353
|
+
}
|
|
354
|
+
/**
|
|
355
|
+
* Facts only — no limits or billing state. Views count share exchanges plus authorized /v1/access grants, deduplicated across the two.
|
|
356
|
+
*
|
|
357
|
+
* @param {CloudPDF.UsageTenantsRequest} request
|
|
358
|
+
* @param {TenantsClient.RequestOptions} requestOptions - Request-specific configuration.
|
|
359
|
+
*
|
|
360
|
+
* @throws {@link CloudPDF.BadRequestError}
|
|
361
|
+
* @throws {@link CloudPDF.NotFoundError}
|
|
362
|
+
* @throws {@link errors.CloudPDFError}
|
|
363
|
+
* @throws {@link errors.CloudPDFTimeoutError}
|
|
364
|
+
*
|
|
365
|
+
* @example
|
|
366
|
+
* await client.tenants.usage({
|
|
367
|
+
* tenantId: "tenantId"
|
|
368
|
+
* })
|
|
369
|
+
*/
|
|
370
|
+
usage(request, requestOptions) {
|
|
371
|
+
return core.HttpResponsePromise.fromPromise(this.__usage(request, requestOptions));
|
|
372
|
+
}
|
|
373
|
+
__usage(request, requestOptions) {
|
|
374
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
375
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
376
|
+
const { tenantId, period } = request;
|
|
377
|
+
const _queryParams = {
|
|
378
|
+
period,
|
|
379
|
+
};
|
|
380
|
+
const _authRequest = yield this._options.authProvider.getAuthRequest();
|
|
381
|
+
const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
|
|
382
|
+
const _response = yield core.fetcher({
|
|
383
|
+
url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment)), `v1/tenants/${core.url.encodePathParam(tenantId)}/usage`),
|
|
384
|
+
method: "GET",
|
|
385
|
+
headers: _headers,
|
|
386
|
+
queryString: core.url
|
|
387
|
+
.queryBuilder()
|
|
388
|
+
.addMany(_queryParams)
|
|
389
|
+
.mergeAdditional(requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams)
|
|
390
|
+
.build(),
|
|
391
|
+
timeoutMs: ((_e = (_c = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _c !== void 0 ? _c : (_d = this._options) === null || _d === void 0 ? void 0 : _d.timeoutInSeconds) !== null && _e !== void 0 ? _e : 60) * 1000,
|
|
392
|
+
maxRetries: (_f = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _f !== void 0 ? _f : (_g = this._options) === null || _g === void 0 ? void 0 : _g.maxRetries,
|
|
393
|
+
abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
|
|
394
|
+
fetchFn: (_h = this._options) === null || _h === void 0 ? void 0 : _h.fetch,
|
|
395
|
+
logging: this._options.logging,
|
|
396
|
+
});
|
|
397
|
+
if (_response.ok) {
|
|
398
|
+
return { data: _response.body, rawResponse: _response.rawResponse };
|
|
399
|
+
}
|
|
400
|
+
if (_response.error.reason === "status-code") {
|
|
401
|
+
switch (_response.error.statusCode) {
|
|
402
|
+
case 400:
|
|
403
|
+
throw new CloudPDF.BadRequestError(_response.error.body, _response.rawResponse);
|
|
404
|
+
case 404:
|
|
405
|
+
throw new CloudPDF.NotFoundError(_response.error.body, _response.rawResponse);
|
|
406
|
+
default:
|
|
407
|
+
throw new errors.CloudPDFError({
|
|
408
|
+
statusCode: _response.error.statusCode,
|
|
409
|
+
body: _response.error.body,
|
|
410
|
+
rawResponse: _response.rawResponse,
|
|
411
|
+
});
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/v1/tenants/{tenantId}/usage");
|
|
415
|
+
});
|
|
416
|
+
}
|
|
236
417
|
}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
export type { DeleteTenantsRequest } from "./DeleteTenantsRequest.mjs";
|
|
2
2
|
export type { GetTenantsRequest } from "./GetTenantsRequest.mjs";
|
|
3
3
|
export type { ListTenantsRequest } from "./ListTenantsRequest.mjs";
|
|
4
|
+
export type { ResumeTenantsRequest } from "./ResumeTenantsRequest.mjs";
|
|
4
5
|
export type { TenantsCreateRequest } from "./TenantsCreateRequest.mjs";
|
|
6
|
+
export type { TenantsSuspendRequest } from "./TenantsSuspendRequest.mjs";
|
|
7
|
+
export type { UsageTenantsRequest } from "./UsageTenantsRequest.mjs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type * as CloudPDF from "../index.mjs";
|
|
2
|
-
export type DocumentsInit200ResponseCreatedUpload = CloudPDF.DocumentsInit200ResponseCreatedUpload.Presigned | CloudPDF.DocumentsInit200ResponseCreatedUpload.
|
|
2
|
+
export type DocumentsInit200ResponseCreatedUpload = CloudPDF.DocumentsInit200ResponseCreatedUpload.Presigned | CloudPDF.DocumentsInit200ResponseCreatedUpload.Proxy;
|
|
3
3
|
export declare namespace DocumentsInit200ResponseCreatedUpload {
|
|
4
4
|
interface Presigned {
|
|
5
5
|
kind: "presigned";
|
|
@@ -20,8 +20,8 @@ export declare namespace DocumentsInit200ResponseCreatedUpload {
|
|
|
20
20
|
type Method = (typeof Method)[keyof typeof Method];
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
|
-
interface
|
|
24
|
-
kind: "
|
|
23
|
+
interface Proxy {
|
|
24
|
+
kind: "proxy";
|
|
25
25
|
url: string;
|
|
26
26
|
key: string;
|
|
27
27
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type * as CloudPDF from "../index.mjs";
|
|
2
|
-
export type DocumentsInit200ResponseResumedUpload = CloudPDF.DocumentsInit200ResponseResumedUpload.Presigned | CloudPDF.DocumentsInit200ResponseResumedUpload.
|
|
2
|
+
export type DocumentsInit200ResponseResumedUpload = CloudPDF.DocumentsInit200ResponseResumedUpload.Presigned | CloudPDF.DocumentsInit200ResponseResumedUpload.Proxy;
|
|
3
3
|
export declare namespace DocumentsInit200ResponseResumedUpload {
|
|
4
4
|
interface Presigned {
|
|
5
5
|
kind: "presigned";
|
|
@@ -20,8 +20,8 @@ export declare namespace DocumentsInit200ResponseResumedUpload {
|
|
|
20
20
|
type Method = (typeof Method)[keyof typeof Method];
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
|
-
interface
|
|
24
|
-
kind: "
|
|
23
|
+
interface Proxy {
|
|
24
|
+
kind: "proxy";
|
|
25
25
|
url: string;
|
|
26
26
|
key: string;
|
|
27
27
|
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface SharesCreate200Response {
|
|
2
|
+
share: SharesCreate200Response.Share;
|
|
3
|
+
}
|
|
4
|
+
export declare namespace SharesCreate200Response {
|
|
5
|
+
interface Share {
|
|
6
|
+
id: string;
|
|
7
|
+
tenantId: string;
|
|
8
|
+
docId: string;
|
|
9
|
+
layerName: string;
|
|
10
|
+
scope: string[];
|
|
11
|
+
origins: string[] | null;
|
|
12
|
+
passwordProtected: boolean;
|
|
13
|
+
sessionTtlSeconds: number;
|
|
14
|
+
disabled: boolean;
|
|
15
|
+
expiresAt: number | null;
|
|
16
|
+
exchangeCount: number;
|
|
17
|
+
lastExchangedAt: number | null;
|
|
18
|
+
createdBy: string;
|
|
19
|
+
createdAt: number;
|
|
20
|
+
updatedAt: number;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface SharesGet200Response {
|
|
2
|
+
share: SharesGet200Response.Share;
|
|
3
|
+
}
|
|
4
|
+
export declare namespace SharesGet200Response {
|
|
5
|
+
interface Share {
|
|
6
|
+
id: string;
|
|
7
|
+
tenantId: string;
|
|
8
|
+
docId: string;
|
|
9
|
+
layerName: string;
|
|
10
|
+
scope: string[];
|
|
11
|
+
origins: string[] | null;
|
|
12
|
+
passwordProtected: boolean;
|
|
13
|
+
sessionTtlSeconds: number;
|
|
14
|
+
disabled: boolean;
|
|
15
|
+
expiresAt: number | null;
|
|
16
|
+
exchangeCount: number;
|
|
17
|
+
lastExchangedAt: number | null;
|
|
18
|
+
createdBy: string;
|
|
19
|
+
createdAt: number;
|
|
20
|
+
updatedAt: number;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export interface SharesList200Response {
|
|
2
|
+
shares: SharesList200Response.Shares.Item[];
|
|
3
|
+
nextCursor?: (string | null) | undefined;
|
|
4
|
+
}
|
|
5
|
+
export declare namespace SharesList200Response {
|
|
6
|
+
type Shares = Shares.Item[];
|
|
7
|
+
namespace Shares {
|
|
8
|
+
interface Item {
|
|
9
|
+
id: string;
|
|
10
|
+
tenantId: string;
|
|
11
|
+
docId: string;
|
|
12
|
+
layerName: string;
|
|
13
|
+
scope: string[];
|
|
14
|
+
origins: string[] | null;
|
|
15
|
+
passwordProtected: boolean;
|
|
16
|
+
sessionTtlSeconds: number;
|
|
17
|
+
disabled: boolean;
|
|
18
|
+
expiresAt: number | null;
|
|
19
|
+
exchangeCount: number;
|
|
20
|
+
lastExchangedAt: number | null;
|
|
21
|
+
createdBy: string;
|
|
22
|
+
createdAt: number;
|
|
23
|
+
updatedAt: number;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface SharesUpdate200Response {
|
|
2
|
+
share: SharesUpdate200Response.Share;
|
|
3
|
+
}
|
|
4
|
+
export declare namespace SharesUpdate200Response {
|
|
5
|
+
interface Share {
|
|
6
|
+
id: string;
|
|
7
|
+
tenantId: string;
|
|
8
|
+
docId: string;
|
|
9
|
+
layerName: string;
|
|
10
|
+
scope: string[];
|
|
11
|
+
origins: string[] | null;
|
|
12
|
+
passwordProtected: boolean;
|
|
13
|
+
sessionTtlSeconds: number;
|
|
14
|
+
disabled: boolean;
|
|
15
|
+
expiresAt: number | null;
|
|
16
|
+
exchangeCount: number;
|
|
17
|
+
lastExchangedAt: number | null;
|
|
18
|
+
createdBy: string;
|
|
19
|
+
createdAt: number;
|
|
20
|
+
updatedAt: number;
|
|
21
|
+
}
|
|
22
|
+
}
|