From 618b54de9bd06837ca78da037aac2a79757503e6 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Thu, 17 Aug 2023 01:41:46 -0700 Subject: [PATCH 1/8] generated with codegen at box/box-codegen@a319f28 and spec at box/box-openapi@e53f5f7 --- src/schemas.generated.ts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/schemas.generated.ts b/src/schemas.generated.ts index fb8aa248..8d0f00ea 100644 --- a/src/schemas.generated.ts +++ b/src/schemas.generated.ts @@ -2544,6 +2544,14 @@ export type SignRequestSigner = SignRequestCreateSigner & { /** * URL to direct a signer to for signing */ readonly embedUrl?: string; + /** + * This URL is specifically designed for + * signing documents within an HTML `iframe` tag. + * It will be returned in the response + * only if the `embed_url_external_user_id` + * parameter was passed in the + * `create sign request` call. */ + readonly iframeableEmbedUrl?: string; }; export interface SignRequestBase { readonly isDocumentPreparationNeeded?: boolean; @@ -10429,7 +10437,7 @@ export function serializeSignRequestSigner(val: SignRequestSigner): Json { } return { ...base, ...{ ["has_viewed_document"]: val.hasViewedDocument == void 0 ? void 0 : val.hasViewedDocument, ["signer_decision"]: val.signerDecision == void 0 ? void 0 : serializeSignRequestSignerSignerDecisionField(val.signerDecision), ["inputs"]: val.inputs == void 0 ? void 0 : val.inputs.map(function (item: SignRequestSignerInput): any { return serializeSignRequestSignerInput(item); - }) as readonly any[], ["embed_url"]: val.embedUrl == void 0 ? void 0 : val.embedUrl } }; + }) as readonly any[], ["embed_url"]: val.embedUrl == void 0 ? void 0 : val.embedUrl, ["iframeable_embed_url"]: val.iframeableEmbedUrl == void 0 ? void 0 : val.iframeableEmbedUrl } }; } export function deserializeSignRequestSigner(val: any): SignRequestSigner { const hasViewedDocument: undefined | boolean = val.has_viewed_document == void 0 ? void 0 : val.has_viewed_document; @@ -10438,6 +10446,7 @@ export function deserializeSignRequestSigner(val: any): SignRequestSigner { return deserializeSignRequestSignerInput(itm); }) as readonly any[] : []; const embedUrl: undefined | string = val.embed_url == void 0 ? void 0 : val.embed_url; + const iframeableEmbedUrl: undefined | string = val.iframeable_embed_url == void 0 ? void 0 : val.iframeable_embed_url; const email: string = val.email; const role: undefined | SignRequestCreateSignerRoleField = val.role == void 0 ? void 0 : deserializeSignRequestCreateSignerRoleField(val.role); const isInPerson: undefined | boolean = val.is_in_person == void 0 ? void 0 : val.is_in_person; @@ -10448,7 +10457,7 @@ export function deserializeSignRequestSigner(val: any): SignRequestSigner { const loginRequired: undefined | boolean = val.login_required == void 0 ? void 0 : val.login_required; const verificationPhoneNumber: undefined | string = val.verification_phone_number == void 0 ? void 0 : val.verification_phone_number; const password: undefined | string = val.password == void 0 ? void 0 : val.password; - return { hasViewedDocument: hasViewedDocument, signerDecision: signerDecision, inputs: inputs, embedUrl: embedUrl, email: email, role: role, isInPerson: isInPerson, order: order, embedUrlExternalUserId: embedUrlExternalUserId, redirectUrl: redirectUrl, declinedRedirectUrl: declinedRedirectUrl, loginRequired: loginRequired, verificationPhoneNumber: verificationPhoneNumber, password: password } satisfies SignRequestSigner; + return { hasViewedDocument: hasViewedDocument, signerDecision: signerDecision, inputs: inputs, embedUrl: embedUrl, iframeableEmbedUrl: iframeableEmbedUrl, email: email, role: role, isInPerson: isInPerson, order: order, embedUrlExternalUserId: embedUrlExternalUserId, redirectUrl: redirectUrl, declinedRedirectUrl: declinedRedirectUrl, loginRequired: loginRequired, verificationPhoneNumber: verificationPhoneNumber, password: password } satisfies SignRequestSigner; } export function serializeSignRequestBase(val: SignRequestBase): Json { return { ["is_document_preparation_needed"]: val.isDocumentPreparationNeeded == void 0 ? void 0 : val.isDocumentPreparationNeeded, ["redirect_url"]: val.redirectUrl == void 0 ? void 0 : val.redirectUrl, ["declined_redirect_url"]: val.declinedRedirectUrl == void 0 ? void 0 : val.declinedRedirectUrl, ["are_text_signatures_enabled"]: val.areTextSignaturesEnabled == void 0 ? void 0 : val.areTextSignaturesEnabled, ["email_subject"]: val.emailSubject == void 0 ? void 0 : val.emailSubject, ["email_message"]: val.emailMessage == void 0 ? void 0 : val.emailMessage, ["are_reminders_enabled"]: val.areRemindersEnabled == void 0 ? void 0 : val.areRemindersEnabled, ["parent_folder"]: serializeFolderMini(val.parentFolder), ["name"]: val.name == void 0 ? void 0 : val.name, ["prefill_tags"]: val.prefillTags == void 0 ? void 0 : val.prefillTags.map(function (item: SignRequestPrefillTag): any { From 0602f43c3db198bc7421b384a59fdf4de1b84dbf Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Mon, 21 Aug 2023 06:03:12 -0700 Subject: [PATCH 2/8] generated with codegen at box/box-codegen@a319f28 and spec at box/box-openapi@9e5ee33 --- docs/storagePolicies.md | 4 +++- docs/storagePolicyAssignments.md | 11 +++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/docs/storagePolicies.md b/docs/storagePolicies.md index 69f8aef8..a3211cff 100644 --- a/docs/storagePolicies.md +++ b/docs/storagePolicies.md @@ -7,6 +7,8 @@ ## List storage policies Fetches all the storage policies in the enterprise. +Only a Primary Admin can access this endpoint. The user +needs to generate a token for an account to authenticate this request. This operation is performed by calling function `getStoragePolicies`. @@ -32,7 +34,7 @@ Returns a collection of storage policies. ## Get storage policy -Fetches a specific storage policy. +Fetches a specific storage policy. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. This operation is performed by calling function `getStoragePolicyById`. diff --git a/docs/storagePolicyAssignments.md b/docs/storagePolicyAssignments.md index ee19ae58..2bb8dc3a 100644 --- a/docs/storagePolicyAssignments.md +++ b/docs/storagePolicyAssignments.md @@ -10,6 +10,8 @@ ## List storage policy assignments Fetches all the storage policy assignment for an enterprise or user. +Only a Primary Admin can access this endpoint. The user +needs to generate a token for an account to authenticate this request. This operation is performed by calling function `getStoragePolicyAssignments`. @@ -37,6 +39,8 @@ the enterprise or user. ## Assign storage policy Creates a storage policy assignment for an enterprise or user. +Only a Primary Admin can access this endpoint. The user +needs to generate a token for an account to authenticate this request. This operation is performed by calling function `createStoragePolicyAssignment`. @@ -62,7 +66,7 @@ Returns the new storage policy assignment created. ## Get storage policy assignment -Fetches a specific storage policy assignment. +Fetches a specific storage policy assignment. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. This operation is performed by calling function `getStoragePolicyAssignmentById`. @@ -88,7 +92,7 @@ Returns a storage policy assignment object. ## Update storage policy assignment -Updates a specific storage policy assignment. +Updates a specific storage policy assignment. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. This operation is performed by calling function `updateStoragePolicyAssignmentById`. @@ -125,6 +129,9 @@ storage policy. There is a rate limit for calling this endpoint of only twice per user in a 24 hour time frame. +Only a Primary Admin can access this endpoint. The user +needs to generate a token for an account to authenticate this request. + This operation is performed by calling function `deleteStoragePolicyAssignmentById`. See the endpoint docs at From ad12b4ac3f1e6e6e60d491b405b5c4bce8059e96 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Wed, 23 Aug 2023 01:36:13 -0700 Subject: [PATCH 3/8] generated with codegen at box/box-codegen@8c1f69f and spec at box/box-openapi@9e5ee33 --- docs/retentionPolicies.md | 25 ++++++-- docs/tasks.md | 25 ++++++-- src/test/retentionPolicies.generated.test.ts | 50 ++++++++++++++++ src/test/tasks.generated.test.ts | 61 ++++++++++++++++++++ 4 files changed, 151 insertions(+), 10 deletions(-) create mode 100644 src/test/retentionPolicies.generated.test.ts create mode 100644 src/test/tasks.generated.test.ts diff --git a/docs/retentionPolicies.md b/docs/retentionPolicies.md index 954ba36d..207c5d9d 100644 --- a/docs/retentionPolicies.md +++ b/docs/retentionPolicies.md @@ -16,7 +16,10 @@ This operation is performed by calling function `getRetentionPolicies`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policies/). -*Currently we don't have an example for calling `getRetentionPolicies` in integration tests* + +```ts +await client.retentionPolicies.getRetentionPolicies() +``` ### Arguments @@ -42,7 +45,10 @@ This operation is performed by calling function `createRetentionPolicy`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-retention-policies/). -*Currently we don't have an example for calling `createRetentionPolicy` in integration tests* + +```ts +await client.retentionPolicies.createRetentionPolicy({ policyName: retentionPolicyName, policyType: "finite" as CreateRetentionPolicyRequestBodyArgPolicyTypeField, areOwnersNotified: true, canOwnerExtendRetention: true, description: retentionDescription, dispositionAction: "remove_retention" as CreateRetentionPolicyRequestBodyArgDispositionActionField, retentionLength: "1", retentionType: "modifiable" as CreateRetentionPolicyRequestBodyArgRetentionTypeField } satisfies CreateRetentionPolicyRequestBodyArg) +``` ### Arguments @@ -68,7 +74,10 @@ This operation is performed by calling function `getRetentionPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policies-id/). -*Currently we don't have an example for calling `getRetentionPolicyById` in integration tests* + +```ts +await client.retentionPolicies.getRetentionPolicyById(retentionPolicy.id) +``` ### Arguments @@ -96,7 +105,10 @@ This operation is performed by calling function `updateRetentionPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-retention-policies-id/). -*Currently we don't have an example for calling `updateRetentionPolicyById` in integration tests* + +```ts +await client.retentionPolicies.updateRetentionPolicyById(retentionPolicy.id, { policyName: updatedRetentionPolicyName } satisfies UpdateRetentionPolicyByIdRequestBodyArg) +``` ### Arguments @@ -124,7 +136,10 @@ This operation is performed by calling function `deleteRetentionPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-retention-policies-id/). -*Currently we don't have an example for calling `deleteRetentionPolicyById` in integration tests* + +```ts +await client.retentionPolicies.deleteRetentionPolicyById(retentionPolicy.id) +``` ### Arguments diff --git a/docs/tasks.md b/docs/tasks.md index 50cbc026..4076ebe6 100644 --- a/docs/tasks.md +++ b/docs/tasks.md @@ -17,7 +17,10 @@ This operation is performed by calling function `getFileTasks`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-tasks/). -*Currently we don't have an example for calling `getFileTasks` in integration tests* + +```ts +await client.tasks.getFileTasks(file.id) +``` ### Arguments @@ -47,7 +50,10 @@ This operation is performed by calling function `createTask`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-tasks/). -*Currently we don't have an example for calling `createTask` in integration tests* + +```ts +await client.tasks.createTask({ item: { type: "file" as CreateTaskRequestBodyArgItemFieldTypeField, id: file.id } satisfies CreateTaskRequestBodyArgItemField, message: "test message", dueAt: "2035-01-01T00:00:00Z", action: "review" as CreateTaskRequestBodyArgActionField, completionRule: "all_assignees" as CreateTaskRequestBodyArgCompletionRuleField } satisfies CreateTaskRequestBodyArg) +``` ### Arguments @@ -73,7 +79,10 @@ This operation is performed by calling function `getTaskById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-tasks-id/). -*Currently we don't have an example for calling `getTaskById` in integration tests* + +```ts +await client.tasks.getTaskById(task.id) +``` ### Arguments @@ -100,7 +109,10 @@ This operation is performed by calling function `updateTaskById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-tasks-id/). -*Currently we don't have an example for calling `updateTaskById` in integration tests* + +```ts +await client.tasks.updateTaskById(task.id, { message: "updated message" } satisfies UpdateTaskByIdRequestBodyArg) +``` ### Arguments @@ -128,7 +140,10 @@ This operation is performed by calling function `deleteTaskById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-tasks-id/). -*Currently we don't have an example for calling `deleteTaskById` in integration tests* + +```ts +await client.tasks.deleteTaskById(task.id) +``` ### Arguments diff --git a/src/test/retentionPolicies.generated.test.ts b/src/test/retentionPolicies.generated.test.ts new file mode 100644 index 00000000..6e9152a7 --- /dev/null +++ b/src/test/retentionPolicies.generated.test.ts @@ -0,0 +1,50 @@ +import { serializeCreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { deserializeCreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { serializeCreateRetentionPolicyRequestBodyArgPolicyTypeField } from "../managers/retentionPolicies.generated.js"; +import { deserializeCreateRetentionPolicyRequestBodyArgPolicyTypeField } from "../managers/retentionPolicies.generated.js"; +import { serializeCreateRetentionPolicyRequestBodyArgDispositionActionField } from "../managers/retentionPolicies.generated.js"; +import { deserializeCreateRetentionPolicyRequestBodyArgDispositionActionField } from "../managers/retentionPolicies.generated.js"; +import { serializeCreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; +import { deserializeCreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; +import { serializeUpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { deserializeUpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { CreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { CreateRetentionPolicyRequestBodyArgPolicyTypeField } from "../managers/retentionPolicies.generated.js"; +import { CreateRetentionPolicyRequestBodyArgDispositionActionField } from "../managers/retentionPolicies.generated.js"; +import { CreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; +import { UpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { decodeBase64 } from "../utils.js"; +import { getEnvVar } from "../utils.js"; +import { getUuid } from "../utils.js"; +import { Client } from "../client.generated.js"; +import { JwtAuth } from "../jwtAuth.js"; +import { JwtConfig } from "../jwtAuth.js"; +const jwtConfig: any = JwtConfig.fromConfigJsonString(decodeBase64(getEnvVar("JWT_CONFIG_BASE_64"))); +const auth: any = new JwtAuth({ config: jwtConfig }); +const client: any = new Client({ auth: auth }); +test("testCreateUpdateGetDeleteRetentionPolicy", async function testCreateUpdateGetDeleteRetentionPolicy(): Promise { + const retentionPolicyName: any = getUuid(); + const retentionDescription: any = "test description"; + const retentionPolicy: any = await client.retentionPolicies.createRetentionPolicy({ policyName: retentionPolicyName, policyType: "finite" as CreateRetentionPolicyRequestBodyArgPolicyTypeField, areOwnersNotified: true, canOwnerExtendRetention: true, description: retentionDescription, dispositionAction: "remove_retention" as CreateRetentionPolicyRequestBodyArgDispositionActionField, retentionLength: "1", retentionType: "modifiable" as CreateRetentionPolicyRequestBodyArgRetentionTypeField } satisfies CreateRetentionPolicyRequestBodyArg); + if (!(retentionPolicy.policyName == retentionPolicyName)) { + throw "Assertion failed"; + } + if (!(retentionPolicy.description == retentionDescription)) { + throw "Assertion failed"; + } + const retentionPolicyById: any = await client.retentionPolicies.getRetentionPolicyById(retentionPolicy.id); + if (!(retentionPolicyById.id == retentionPolicy.id)) { + throw "Assertion failed"; + } + const retentionPolicies: any = await client.retentionPolicies.getRetentionPolicies(); + if (!(retentionPolicies.entries.length > 0)) { + throw "Assertion failed"; + } + const updatedRetentionPolicyName: any = getUuid(); + const updatedRetentionPolicy: any = await client.retentionPolicies.updateRetentionPolicyById(retentionPolicy.id, { policyName: updatedRetentionPolicyName } satisfies UpdateRetentionPolicyByIdRequestBodyArg); + if (!(updatedRetentionPolicy.policyName == updatedRetentionPolicyName)) { + throw "Assertion failed"; + } + await client.retentionPolicies.deleteRetentionPolicyById(retentionPolicy.id) +}); +export {}; diff --git a/src/test/tasks.generated.test.ts b/src/test/tasks.generated.test.ts new file mode 100644 index 00000000..64a3e4b8 --- /dev/null +++ b/src/test/tasks.generated.test.ts @@ -0,0 +1,61 @@ +import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; +import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; +import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeCreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; +import { deserializeCreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; +import { serializeCreateTaskRequestBodyArgItemField } from "../managers/tasks.generated.js"; +import { deserializeCreateTaskRequestBodyArgItemField } from "../managers/tasks.generated.js"; +import { serializeCreateTaskRequestBodyArgItemFieldTypeField } from "../managers/tasks.generated.js"; +import { deserializeCreateTaskRequestBodyArgItemFieldTypeField } from "../managers/tasks.generated.js"; +import { serializeCreateTaskRequestBodyArgActionField } from "../managers/tasks.generated.js"; +import { deserializeCreateTaskRequestBodyArgActionField } from "../managers/tasks.generated.js"; +import { serializeCreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; +import { deserializeCreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; +import { serializeUpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; +import { deserializeUpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; +import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; +import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; +import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { CreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; +import { CreateTaskRequestBodyArgItemField } from "../managers/tasks.generated.js"; +import { CreateTaskRequestBodyArgItemFieldTypeField } from "../managers/tasks.generated.js"; +import { CreateTaskRequestBodyArgActionField } from "../managers/tasks.generated.js"; +import { CreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; +import { UpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; +import { decodeBase64 } from "../utils.js"; +import { getEnvVar } from "../utils.js"; +import { getUuid } from "../utils.js"; +import { generateByteStream } from "../utils.js"; +import { Client } from "../client.generated.js"; +import { JwtAuth } from "../jwtAuth.js"; +import { JwtConfig } from "../jwtAuth.js"; +const jwtConfig: any = JwtConfig.fromConfigJsonString(decodeBase64(getEnvVar("JWT_CONFIG_BASE_64"))); +const auth: any = new JwtAuth({ config: jwtConfig }); +const client: any = new Client({ auth: auth }); +test("testCreateUpdateGetDeleteTask", async function testCreateUpdateGetDeleteTask(): Promise { + const files: any = await client.uploads.uploadFile({ attributes: { name: getUuid(), parent: { id: "0" } satisfies UploadFileRequestBodyArgAttributesFieldParentField } satisfies UploadFileRequestBodyArgAttributesField, file: generateByteStream(10) } satisfies UploadFileRequestBodyArg); + const file: any = files.entries[0]; + const task: any = await client.tasks.createTask({ item: { type: "file" as CreateTaskRequestBodyArgItemFieldTypeField, id: file.id } satisfies CreateTaskRequestBodyArgItemField, message: "test message", dueAt: "2035-01-01T00:00:00Z", action: "review" as CreateTaskRequestBodyArgActionField, completionRule: "all_assignees" as CreateTaskRequestBodyArgCompletionRuleField } satisfies CreateTaskRequestBodyArg); + if (!(task.message == "test message")) { + throw "Assertion failed"; + } + if (!(task.item.id == file.id)) { + throw "Assertion failed"; + } + const taskById: any = await client.tasks.getTaskById(task.id); + if (!(taskById.id == task.id)) { + throw "Assertion failed"; + } + const taskOnFile: any = await client.tasks.getFileTasks(file.id); + if (!(taskOnFile.totalCount == 1)) { + throw "Assertion failed"; + } + const updatedTask: any = await client.tasks.updateTaskById(task.id, { message: "updated message" } satisfies UpdateTaskByIdRequestBodyArg); + if (!(updatedTask.message == "updated message")) { + throw "Assertion failed"; + } + await client.tasks.deleteTaskById(task.id) + await client.files.deleteFileById(file.id) +}); +export {}; From a4fa2bf6ca0c3194a0c5d730336e1fda760d7933 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Mon, 28 Aug 2023 01:05:40 -0700 Subject: [PATCH 4/8] generated with codegen at box/box-codegen@ecb4aec and spec at box/box-openapi@9e5ee33 --- src/test/folderLocks.generated.test.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/test/folderLocks.generated.test.ts b/src/test/folderLocks.generated.test.ts index 2a2d2f68..aaf07979 100644 --- a/src/test/folderLocks.generated.test.ts +++ b/src/test/folderLocks.generated.test.ts @@ -39,7 +39,6 @@ test("testFolderLocks", async function testFolderLocks(): Promise { if (!(folderLock.lockedOperations.delete == true)) { throw "Assertion failed"; } - expect(async () => { await client.folders.deleteFolderById(folder.id); }).rejects.toThrow(); await client.folderLocks.deleteFolderLockById(folderLock.id) expect(async () => { await client.folderLocks.deleteFolderLockById(folderLock.id); }).rejects.toThrow(); const newFolderLocks: any = await client.folderLocks.getFolderLocks({ folderId: folder.id } satisfies GetFolderLocksQueryParamsArg); From a93d66179ec00b4fdf9e58768667f089a7f0dbd1 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Wed, 30 Aug 2023 03:34:26 -0700 Subject: [PATCH 5/8] generated with codegen at box/box-codegen@7401b20 and spec at box/box-openapi@9e5ee33 --- src/client.generated.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/client.generated.ts b/src/client.generated.ts index 1209f7bc..e2d0de49 100644 --- a/src/client.generated.ts +++ b/src/client.generated.ts @@ -69,7 +69,7 @@ import { IntegrationMappingsManager } from "./managers/integrationMappings.gener import { Authentication } from "./auth.js"; import { NetworkSession } from "./network.js"; export class Client { - readonly auth?: Authentication; + readonly auth!: Authentication; readonly networkSession?: NetworkSession = {} satisfies NetworkSession; readonly authorization: AuthorizationManager; readonly files: FilesManager; From 79c9165aabe3653fc7842229888d870131e2b1d3 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Thu, 31 Aug 2023 08:01:03 -0700 Subject: [PATCH 6/8] generated with codegen at box/box-codegen@d8b234c and spec at box/box-openapi@9e5ee33 --- docs/authorization.md | 6 +-- docs/avatars.md | 31 +++++------ docs/chunkedUploads.md | 48 ++++++++--------- docs/classifications.md | 26 +++------- docs/collaborationAllowlistEntries.md | 18 ++----- docs/collaborationAllowlistExemptTargets.md | 18 ++----- docs/collections.md | 12 ++--- docs/comments.md | 37 +++++++------- docs/devicePinners.md | 14 ++--- docs/emailAliases.md | 19 +++---- docs/events.md | 10 +--- docs/fileClassifications.md | 26 +++------- docs/fileMetadata.md | 43 ++++++++-------- docs/fileRequests.md | 26 +++------- docs/fileVersionLegalHolds.md | 10 +--- docs/fileVersionRetentions.md | 10 +--- docs/fileVersions.md | 32 ++++-------- docs/fileWatermarks.md | 20 +++----- docs/folderClassifications.md | 26 +++------- docs/folderLocks.md | 28 ++++++---- docs/folderMetadata.md | 32 ++++-------- docs/folderWatermarks.md | 20 +++----- docs/groups.md | 31 +++++------ docs/integrationMappings.md | 19 ++----- docs/invites.md | 10 +--- docs/legalHoldPolicies.md | 22 ++------ docs/legalHoldPolicyAssignments.md | 26 +++------- docs/listCollaborations.md | 22 +++----- docs/memberships.md | 37 +++++++------- docs/metadataCascadePolicies.md | 22 ++------ docs/metadataTemplates.md | 51 +++++++++---------- docs/recentItems.md | 7 +-- docs/retentionPolicies.md | 40 ++++++++------- docs/retentionPolicyAssignments.md | 26 +++------- docs/search.md | 14 ++--- docs/sessionTermination.md | 10 +--- docs/sharedLinksFiles.md | 30 ++++------- docs/sharedLinksFolders.md | 30 ++++------- docs/sharedLinksWebLinks.md | 22 ++------ docs/shieldInformationBarrierReports.md | 16 ++---- .../shieldInformationBarrierSegmentMembers.md | 18 ++----- ...ldInformationBarrierSegmentRestrictions.md | 18 ++----- docs/shieldInformationBarrierSegments.md | 22 ++------ docs/shieldInformationBarriers.md | 18 ++----- docs/signTemplates.md | 10 +--- docs/skills.md | 30 ++++------- docs/storagePolicies.md | 10 +--- docs/storagePolicyAssignments.md | 22 ++------ docs/taskAssignments.md | 22 ++------ docs/tasks.md | 41 ++++++++------- docs/termsOfServiceUserStatuses.md | 14 ++--- docs/termsOfServices.md | 18 ++----- docs/transfer.md | 6 +-- docs/trashedFiles.md | 23 ++++----- docs/trashedFolders.md | 23 ++++----- docs/trashedItems.md | 6 +-- docs/trashedWebLinks.md | 16 ++---- docs/userCollaborations.md | 23 +++------ docs/users.md | 38 +++++++------- docs/webLinks.md | 33 +++++++----- docs/webhooks.md | 36 ++++++------- docs/workflows.md | 10 +--- docs/zipDownloads.md | 14 ++--- package.json | 2 +- src/managers/files.generated.ts | 4 +- src/managers/folders.generated.ts | 4 +- src/managers/metadataTemplates.generated.ts | 12 ++--- src/managers/sessionTermination.generated.ts | 12 ++--- src/schemas.generated.ts | 36 ++++++------- src/test/avatars.generated.test.ts | 6 +++ src/test/chunkedUploads.generated.test.ts | 20 +++++++- src/test/collections.generated.test.ts | 12 +++++ src/test/comments.generated.test.ts | 10 ++++ src/test/commons.generated.ts | 14 ++++- src/test/downloads.generated.test.ts | 8 +++ src/test/emailAliases.generated.test.ts | 9 ++++ src/test/fileMetadata.generated.test.ts | 12 +++++ src/test/files.generated.test.ts | 15 +++++- src/test/folderLocks.generated.test.ts | 9 ++++ src/test/folders.generated.test.ts | 6 +++ src/test/groups.generated.test.ts | 9 ++++ src/test/memberships.generated.test.ts | 12 +++++ src/test/metadataTemplates.generated.test.ts | 6 +++ src/test/recentItems.generated.test.ts | 3 ++ src/test/retentionPolicies.generated.test.ts | 6 +++ src/test/signRequests.generated.test.ts | 12 +++++ src/test/tasks.generated.test.ts | 12 +++++ src/test/trashedFiles.generated.test.ts | 16 ++++++ src/test/trashedFolders.generated.test.ts | 9 ++++ src/test/uploads.generated.test.ts | 7 +++ src/test/users.generated.test.ts | 9 ++++ src/test/webhooks.generated.test.ts | 9 ++++ src/test/weblinks.generated.test.ts | 6 +++ src/utils.ts | 11 ++++ tsconfig.json | 11 ++-- tsconfig.test.json | 5 +- 96 files changed, 783 insertions(+), 969 deletions(-) diff --git a/docs/authorization.md b/docs/authorization.md index 1d76eec4..c73e90fb 100644 --- a/docs/authorization.md +++ b/docs/authorization.md @@ -1,6 +1,5 @@ # AuthorizationManager - - [Authorize user](#authorize-user) ## Authorize user @@ -18,7 +17,7 @@ This operation is performed by calling function `getAuthorize`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-authorize/). -*Currently we don't have an example for calling `getAuthorize` in integration tests* +_Currently we don't have an example for calling `getAuthorize` in integration tests_ ### Arguments @@ -27,11 +26,8 @@ See the endpoint docs at - headers `GetAuthorizeHeadersArg` - Headers of getAuthorize method - ### Returns This function returns a value of type `undefined`. Does not return any data, but rather should be used in the browser. - - diff --git a/docs/avatars.md b/docs/avatars.md index bf0845fb..62679b44 100644 --- a/docs/avatars.md +++ b/docs/avatars.md @@ -1,6 +1,5 @@ # AvatarsManager - - [Get user avatar](#get-user-avatar) - [Add or update user avatar](#add-or-update-user-avatar) - [Delete user avatar](#delete-user-avatar) @@ -15,8 +14,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users-id-avatar/). + ```ts -await client.avatars.getUserAvatar(user.id) +await client.avatars.getUserAvatar(user.id); ``` ### Arguments @@ -26,7 +26,6 @@ await client.avatars.getUserAvatar(user.id) - headers `GetUserAvatarHeadersArg` - Headers of getUserAvatar method - ### Returns This function returns a value of type `ByteStream`. @@ -35,7 +34,6 @@ When an avatar can be found for the user the image data will be returned in the body of the response. - ## Add or update user avatar Adds or updates a user avatar. @@ -46,8 +44,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-users-id-avatar/). + ```ts -await client.avatars.createUserAvatar(user.id, { pic: decodeBase64ByteStream("iVBORw0KGgoAAAANSUhEUgAAAQAAAAEAAQMAAABmvDolAAAAA1BMVEW10NBjBBbqAAAAH0lEQVRoge3BAQ0AAADCoPdPbQ43oAAAAAAAAAAAvg0hAAABmmDh1QAAAABJRU5ErkJggg=="), picContentType: "image/png", picFileName: "avatar.png" } satisfies CreateUserAvatarRequestBodyArg) +await client.avatars.createUserAvatar(user.id, { + pic: decodeBase64ByteStream( + 'iVBORw0KGgoAAAANSUhEUgAAAQAAAAEAAQMAAABmvDolAAAAA1BMVEW10NBjBBbqAAAAH0lEQVRoge3BAQ0AAADCoPdPbQ43oAAAAAAAAAAAvg0hAAABmmDh1QAAAABJRU5ErkJggg==' + ), + picContentType: 'image/png', + picFileName: 'avatar.png', +} satisfies CreateUserAvatarRequestBodyArg); ``` ### Arguments @@ -59,15 +64,13 @@ await client.avatars.createUserAvatar(user.id, { pic: decodeBase64ByteStream("iV - headers `CreateUserAvatarHeadersArg` - Headers of createUserAvatar method - ### Returns This function returns a value of type `UserAvatar`. -* `ok`: Returns the `pic_urls` object with URLs to existing -user avatars that were updated.* `created`: Returns the `pic_urls` object with URLS to user avatars -uploaded to Box with the request. - +- `ok`: Returns the `pic_urls` object with URLs to existing + user avatars that were updated.\* `created`: Returns the `pic_urls` object with URLS to user avatars + uploaded to Box with the request. ## Delete user avatar @@ -80,8 +83,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-users-id-avatar/). + ```ts -await client.avatars.deleteUserAvatar(user.id) +await client.avatars.deleteUserAvatar(user.id); ``` ### Arguments @@ -91,11 +95,8 @@ await client.avatars.deleteUserAvatar(user.id) - headers `DeleteUserAvatarHeadersArg` - Headers of deleteUserAvatar method - ### Returns This function returns a value of type `undefined`. -* `no_content`: Removes the avatar and returns an empty response. - - +- `no_content`: Removes the avatar and returns an empty response. diff --git a/docs/chunkedUploads.md b/docs/chunkedUploads.md index 355a00ab..4be988a7 100644 --- a/docs/chunkedUploads.md +++ b/docs/chunkedUploads.md @@ -20,8 +20,13 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-upload-sessions/). + ```ts -await client.chunkedUploads.createFileUploadSession({ fileName: fileName, fileSize: fileSize, folderId: folderId } satisfies CreateFileUploadSessionRequestBodyArg) +await client.chunkedUploads.createFileUploadSession({ + fileName: fileName, + fileSize: fileSize, + folderId: folderId, +} satisfies CreateFileUploadSessionRequestBodyArg); ``` ### Arguments @@ -31,14 +36,12 @@ await client.chunkedUploads.createFileUploadSession({ fileName: fileName, fileSi - headers `CreateFileUploadSessionHeadersArg` - Headers of createFileUploadSession method - ### Returns This function returns a value of type `UploadSession`. Returns a new upload session. - ## Create upload session for existing file Creates an upload session for an existing file. @@ -48,25 +51,23 @@ This operation is performed by calling function `createFileUploadSessionForExist See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id-upload-sessions/). -*Currently we don't have an example for calling `createFileUploadSessionForExistingFile` in integration tests* +_Currently we don't have an example for calling `createFileUploadSessionForExistingFile` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `CreateFileUploadSessionForExistingFileRequestBodyArg` - Request body of createFileUploadSessionForExistingFile method - headers `CreateFileUploadSessionForExistingFileHeadersArg` - Headers of createFileUploadSessionForExistingFile method - ### Returns This function returns a value of type `UploadSession`. Returns a new upload session. - ## Get upload session Return information about an upload session. @@ -77,8 +78,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-upload-sessions-id/). + ```ts -await client.chunkedUploads.getFileUploadSessionById(uploadSessionId) +await client.chunkedUploads.getFileUploadSessionById(uploadSessionId); ``` ### Arguments @@ -88,14 +90,12 @@ await client.chunkedUploads.getFileUploadSessionById(uploadSessionId) - headers `GetFileUploadSessionByIdHeadersArg` - Headers of getFileUploadSessionById method - ### Returns This function returns a value of type `UploadSession`. Returns an upload session object. - ## Upload part of file Updates a chunk of an upload session for a file. @@ -106,8 +106,13 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-upload-sessions-id/). + ```ts -await client.chunkedUploads.uploadFilePart(uploadSessionId, uploadedChunk, new UploadFilePartHeadersArg({ digest: digest, contentRange: contentRange })) +await client.chunkedUploads.uploadFilePart( + uploadSessionId, + uploadedChunk, + new UploadFilePartHeadersArg({ digest: digest, contentRange: contentRange }) +); ``` ### Arguments @@ -119,14 +124,12 @@ await client.chunkedUploads.uploadFilePart(uploadSessionId, uploadedChunk, new U - headers `UploadFilePartHeadersArg` - Headers of uploadFilePart method - ### Returns This function returns a value of type `UploadedPart`. Chunk has been uploaded successfully. - ## Remove upload session Abort an upload session and discard all data uploaded. @@ -138,7 +141,7 @@ This operation is performed by calling function `deleteFileUploadSessionById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-upload-sessions-id/). -*Currently we don't have an example for calling `deleteFileUploadSessionById` in integration tests* +_Currently we don't have an example for calling `deleteFileUploadSessionById` in integration tests_ ### Arguments @@ -147,7 +150,6 @@ See the endpoint docs at - headers `DeleteFileUploadSessionByIdHeadersArg` - Headers of deleteFileUploadSessionById method - ### Returns This function returns a value of type `undefined`. @@ -155,7 +157,6 @@ This function returns a value of type `undefined`. A blank response is returned if the session was successfully aborted. - ## List parts Return a list of the chunks uploaded to the upload @@ -167,8 +168,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-upload-sessions-id-parts/). + ```ts -await client.chunkedUploads.getFileUploadSessionParts(uploadSessionId) +await client.chunkedUploads.getFileUploadSessionParts(uploadSessionId); ``` ### Arguments @@ -180,14 +182,12 @@ await client.chunkedUploads.getFileUploadSessionParts(uploadSessionId) - headers `GetFileUploadSessionPartsHeadersArg` - Headers of getFileUploadSessionParts method - ### Returns This function returns a value of type `UploadParts`. Returns a list of parts that have been uploaded. - ## Commit upload session Close an upload session and create a file from the @@ -199,8 +199,13 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-upload-sessions-id-commit/). + ```ts -await client.chunkedUploads.createFileUploadSessionCommit(uploadSessionId, { parts: parts } satisfies CreateFileUploadSessionCommitRequestBodyArg, new CreateFileUploadSessionCommitHeadersArg({ digest: digest })) +await client.chunkedUploads.createFileUploadSessionCommit( + uploadSessionId, + { parts: parts } satisfies CreateFileUploadSessionCommitRequestBodyArg, + new CreateFileUploadSessionCommitHeadersArg({ digest: digest }) +); ``` ### Arguments @@ -212,7 +217,6 @@ await client.chunkedUploads.createFileUploadSessionCommit(uploadSessionId, { par - headers `CreateFileUploadSessionCommitHeadersArg` - Headers of createFileUploadSessionCommit method - ### Returns This function returns a value of type `Files`. @@ -222,5 +226,3 @@ Returns the file object in a list.Returns when all chunks have been uploaded but Inspect the upload session to get more information about the progress of processing the chunks, then retry committing the file when all chunks have processed. - - diff --git a/docs/classifications.md b/docs/classifications.md index 47402cab..e0fc6eac 100644 --- a/docs/classifications.md +++ b/docs/classifications.md @@ -1,6 +1,5 @@ # ClassificationsManager - - [List all classifications](#list-all-classifications) - [Delete all classifications](#delete-all-classifications) - [Add classification](#add-classification) @@ -22,14 +21,13 @@ This operation is performed by calling function `getMetadataTemplateEnterpriseSe See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates-enterprise-security-classification-6-vm-vochw-u-wo-schema/). -*Currently we don't have an example for calling `getMetadataTemplateEnterpriseSecurityClassificationSchema` in integration tests* +_Currently we don't have an example for calling `getMetadataTemplateEnterpriseSecurityClassificationSchema` in integration tests_ ### Arguments - headers `GetMetadataTemplateEnterpriseSecurityClassificationSchemaHeadersArg` - Headers of getMetadataTemplateEnterpriseSecurityClassificationSchema method - ### Returns This function returns a value of type `ClassificationTemplate`. @@ -38,7 +36,6 @@ Returns the `securityClassification` metadata template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Delete all classifications Delete all classifications by deleting the classification @@ -49,14 +46,13 @@ This operation is performed by calling function `deleteMetadataTemplateEnterpris See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-metadata-templates-enterprise-security-classification-6-vm-vochw-u-wo-schema/). -*Currently we don't have an example for calling `deleteMetadataTemplateEnterpriseSecurityClassificationSchema` in integration tests* +_Currently we don't have an example for calling `deleteMetadataTemplateEnterpriseSecurityClassificationSchema` in integration tests_ ### Arguments - headers `DeleteMetadataTemplateEnterpriseSecurityClassificationSchemaHeadersArg` - Headers of deleteMetadataTemplateEnterpriseSecurityClassificationSchema method - ### Returns This function returns a value of type `undefined`. @@ -64,7 +60,6 @@ This function returns a value of type `undefined`. Returns an empty response when the metadata template for classifications is successfully deleted. - ## Add classification Adds one or more new classifications to the list of classifications @@ -79,7 +74,7 @@ This operation is performed by calling function `updateMetadataTemplateEnterpris See the endpoint docs at [API Reference](https://developer.box.com/reference/put-metadata-templates-enterprise-security-classification-6-vm-vochw-u-wo-schema-add/). -*Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaAdd` in integration tests* +_Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaAdd` in integration tests_ ### Arguments @@ -88,7 +83,6 @@ See the endpoint docs at - headers `UpdateMetadataTemplateEnterpriseSecurityClassificationSchemaAddHeadersArg` - Headers of updateMetadataTemplateEnterpriseSecurityClassificationSchemaAdd method - ### Returns This function returns a value of type `ClassificationTemplate`. @@ -97,7 +91,6 @@ Returns the updated `securityClassification` metadata template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Update classification Updates the labels and descriptions of one or more classifications @@ -112,7 +105,7 @@ This operation is performed by calling function `updateMetadataTemplateEnterpris See the endpoint docs at [API Reference](https://developer.box.com/reference/put-metadata-templates-enterprise-security-classification-6-vm-vochw-u-wo-schema-update/). -*Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaUpdate` in integration tests* +_Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaUpdate` in integration tests_ ### Arguments @@ -121,7 +114,6 @@ See the endpoint docs at - headers `UpdateMetadataTemplateEnterpriseSecurityClassificationSchemaUpdateHeadersArg` - Headers of updateMetadataTemplateEnterpriseSecurityClassificationSchemaUpdate method - ### Returns This function returns a value of type `ClassificationTemplate`. @@ -130,7 +122,6 @@ Returns the updated `securityClassification` metadata template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Delete classification Removes a classification from the list of classifications @@ -145,7 +136,7 @@ This operation is performed by calling function `updateMetadataTemplateEnterpris See the endpoint docs at [API Reference](https://developer.box.com/reference/put-metadata-templates-enterprise-security-classification-6-vm-vochw-u-wo-schema-delete/). -*Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaDelete` in integration tests* +_Currently we don't have an example for calling `updateMetadataTemplateEnterpriseSecurityClassificationSchemaDelete` in integration tests_ ### Arguments @@ -154,7 +145,6 @@ See the endpoint docs at - headers `UpdateMetadataTemplateEnterpriseSecurityClassificationSchemaDeleteHeadersArg` - Headers of updateMetadataTemplateEnterpriseSecurityClassificationSchemaDelete method - ### Returns This function returns a value of type `ClassificationTemplate`. @@ -163,7 +153,6 @@ Returns the updated `securityClassification` metadata template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Add initial classifications When an enterprise does not yet have any classifications, this API call @@ -179,7 +168,7 @@ This operation is performed by calling function `createMetadataTemplateSchemaCla See the endpoint docs at [API Reference](https://developer.box.com/reference/post-metadata-templates-schema-classifications/). -*Currently we don't have an example for calling `createMetadataTemplateSchemaClassification` in integration tests* +_Currently we don't have an example for calling `createMetadataTemplateSchemaClassification` in integration tests_ ### Arguments @@ -188,7 +177,6 @@ See the endpoint docs at - headers `CreateMetadataTemplateSchemaClassificationHeadersArg` - Headers of createMetadataTemplateSchemaClassification method - ### Returns This function returns a value of type `ClassificationTemplate`. @@ -196,5 +184,3 @@ This function returns a value of type `ClassificationTemplate`. Returns a new `securityClassification` metadata template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - - diff --git a/docs/collaborationAllowlistEntries.md b/docs/collaborationAllowlistEntries.md index 41ed5aea..ae23ecf6 100644 --- a/docs/collaborationAllowlistEntries.md +++ b/docs/collaborationAllowlistEntries.md @@ -1,6 +1,5 @@ # CollaborationAllowlistEntriesManager - - [List allowed collaboration domains](#list-allowed-collaboration-domains) - [Add domain to list of allowed collaboration domains](#add-domain-to-list-of-allowed-collaboration-domains) - [Get allowed collaboration domain](#get-allowed-collaboration-domain) @@ -16,7 +15,7 @@ This operation is performed by calling function `getCollaborationWhitelistEntrie See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaboration-whitelist-entries/). -*Currently we don't have an example for calling `getCollaborationWhitelistEntries` in integration tests* +_Currently we don't have an example for calling `getCollaborationWhitelistEntries` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `GetCollaborationWhitelistEntriesHeadersArg` - Headers of getCollaborationWhitelistEntries method - ### Returns This function returns a value of type `CollaborationAllowlistEntries`. Returns a collection of domains that are allowed for collaboration. - ## Add domain to list of allowed collaboration domains Creates a new entry in the list of allowed domains to allow @@ -43,7 +40,7 @@ This operation is performed by calling function `createCollaborationWhitelistEnt See the endpoint docs at [API Reference](https://developer.box.com/reference/post-collaboration-whitelist-entries/). -*Currently we don't have an example for calling `createCollaborationWhitelistEntry` in integration tests* +_Currently we don't have an example for calling `createCollaborationWhitelistEntry` in integration tests_ ### Arguments @@ -52,14 +49,12 @@ See the endpoint docs at - headers `CreateCollaborationWhitelistEntryHeadersArg` - Headers of createCollaborationWhitelistEntry method - ### Returns This function returns a value of type `CollaborationAllowlistEntry`. Returns a new entry on the list of allowed domains. - ## Get allowed collaboration domain Returns a domain that has been deemed safe to create collaborations @@ -70,7 +65,7 @@ This operation is performed by calling function `getCollaborationWhitelistEntryB See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaboration-whitelist-entries-id/). -*Currently we don't have an example for calling `getCollaborationWhitelistEntryById` in integration tests* +_Currently we don't have an example for calling `getCollaborationWhitelistEntryById` in integration tests_ ### Arguments @@ -79,14 +74,12 @@ See the endpoint docs at - headers `GetCollaborationWhitelistEntryByIdHeadersArg` - Headers of getCollaborationWhitelistEntryById method - ### Returns This function returns a value of type `CollaborationAllowlistEntry`. Returns an entry on the list of allowed domains. - ## Remove domain from list of allowed collaboration domains Removes a domain from the list of domains that have been deemed safe to create @@ -97,7 +90,7 @@ This operation is performed by calling function `deleteCollaborationWhitelistEnt See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-collaboration-whitelist-entries-id/). -*Currently we don't have an example for calling `deleteCollaborationWhitelistEntryById` in integration tests* +_Currently we don't have an example for calling `deleteCollaborationWhitelistEntryById` in integration tests_ ### Arguments @@ -106,12 +99,9 @@ See the endpoint docs at - headers `DeleteCollaborationWhitelistEntryByIdHeadersArg` - Headers of deleteCollaborationWhitelistEntryById method - ### Returns This function returns a value of type `undefined`. A blank response is returned if the entry was successfully deleted. - - diff --git a/docs/collaborationAllowlistExemptTargets.md b/docs/collaborationAllowlistExemptTargets.md index a1ad7ba5..27717a94 100644 --- a/docs/collaborationAllowlistExemptTargets.md +++ b/docs/collaborationAllowlistExemptTargets.md @@ -1,6 +1,5 @@ # CollaborationAllowlistExemptTargetsManager - - [List users exempt from collaboration domain restrictions](#list-users-exempt-from-collaboration-domain-restrictions) - [Create user exemption from collaboration domain restrictions](#create-user-exemption-from-collaboration-domain-restrictions) - [Get user exempt from collaboration domain restrictions](#get-user-exempt-from-collaboration-domain-restrictions) @@ -16,7 +15,7 @@ This operation is performed by calling function `getCollaborationWhitelistExempt See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaboration-whitelist-exempt-targets/). -*Currently we don't have an example for calling `getCollaborationWhitelistExemptTargets` in integration tests* +_Currently we don't have an example for calling `getCollaborationWhitelistExemptTargets` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `GetCollaborationWhitelistExemptTargetsHeadersArg` - Headers of getCollaborationWhitelistExemptTargets method - ### Returns This function returns a value of type `CollaborationAllowlistExemptTargets`. Returns a collection of user exemptions. - ## Create user exemption from collaboration domain restrictions Exempts a user from the restrictions set out by the allowed list of domains @@ -43,7 +40,7 @@ This operation is performed by calling function `createCollaborationWhitelistExe See the endpoint docs at [API Reference](https://developer.box.com/reference/post-collaboration-whitelist-exempt-targets/). -*Currently we don't have an example for calling `createCollaborationWhitelistExemptTarget` in integration tests* +_Currently we don't have an example for calling `createCollaborationWhitelistExemptTarget` in integration tests_ ### Arguments @@ -52,14 +49,12 @@ See the endpoint docs at - headers `CreateCollaborationWhitelistExemptTargetHeadersArg` - Headers of createCollaborationWhitelistExemptTarget method - ### Returns This function returns a value of type `CollaborationAllowlistExemptTarget`. Returns a new exemption entry. - ## Get user exempt from collaboration domain restrictions Returns a users who has been exempt from the collaboration @@ -70,7 +65,7 @@ This operation is performed by calling function `getCollaborationWhitelistExempt See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaboration-whitelist-exempt-targets-id/). -*Currently we don't have an example for calling `getCollaborationWhitelistExemptTargetById` in integration tests* +_Currently we don't have an example for calling `getCollaborationWhitelistExemptTargetById` in integration tests_ ### Arguments @@ -79,14 +74,12 @@ See the endpoint docs at - headers `GetCollaborationWhitelistExemptTargetByIdHeadersArg` - Headers of getCollaborationWhitelistExemptTargetById method - ### Returns This function returns a value of type `CollaborationAllowlistExemptTarget`. Returns the user's exempted from the list of collaboration domains. - ## Remove user from list of users exempt from domain restrictions Removes a user's exemption from the restrictions set out by the allowed list @@ -97,7 +90,7 @@ This operation is performed by calling function `deleteCollaborationWhitelistExe See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-collaboration-whitelist-exempt-targets-id/). -*Currently we don't have an example for calling `deleteCollaborationWhitelistExemptTargetById` in integration tests* +_Currently we don't have an example for calling `deleteCollaborationWhitelistExemptTargetById` in integration tests_ ### Arguments @@ -106,12 +99,9 @@ See the endpoint docs at - headers `DeleteCollaborationWhitelistExemptTargetByIdHeadersArg` - Headers of deleteCollaborationWhitelistExemptTargetById method - ### Returns This function returns a value of type `undefined`. A blank response is returned if the exemption was successfully deleted. - - diff --git a/docs/collections.md b/docs/collections.md index 5227e3d5..1bbb68c7 100644 --- a/docs/collections.md +++ b/docs/collections.md @@ -1,6 +1,5 @@ # CollectionsManager - - [List all collections](#list-all-collections) - [List collection items](#list-collection-items) @@ -17,8 +16,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collections/). + ```ts -await client.collections.getCollections() +await client.collections.getCollections(); ``` ### Arguments @@ -28,14 +28,12 @@ await client.collections.getCollections() - headers `GetCollectionsHeadersArg` - Headers of getCollections method - ### Returns This function returns a value of type `Collections`. Returns all collections for the given user - ## List collection items Retrieves the files and/or folders contained within @@ -47,8 +45,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collections-id-items/). + ```ts -await client.collections.getCollectionItems(favouriteCollection.id) +await client.collections.getCollectionItems(favouriteCollection.id); ``` ### Arguments @@ -60,11 +59,8 @@ await client.collections.getCollectionItems(favouriteCollection.id) - headers `GetCollectionItemsHeadersArg` - Headers of getCollectionItems method - ### Returns This function returns a value of type `Items`. Returns an array of items in the collection. - - diff --git a/docs/comments.md b/docs/comments.md index b23eeee7..d495f248 100644 --- a/docs/comments.md +++ b/docs/comments.md @@ -1,6 +1,5 @@ # CommentsManager - - [List file comments](#list-file-comments) - [Get comment](#get-comment) - [Update comment](#update-comment) @@ -17,20 +16,20 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-comments/). + ```ts -await client.comments.getFileComments(fileId) +await client.comments.getFileComments(fileId); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - queryParams `GetFileCommentsQueryParamsArg` - Query parameters of getFileComments method - headers `GetFileCommentsHeadersArg` - Headers of getFileComments method - ### Returns This function returns a value of type `Comments`. @@ -38,7 +37,6 @@ This function returns a value of type `Comments`. Returns a collection of comment objects. If there are no comments on this file an empty collection will be returned. - ## Get comment Retrieves the message and metadata for a specific comment, as well @@ -50,8 +48,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-comments-id/). + ```ts -await client.comments.getCommentById(newComment.id) +await client.comments.getCommentById(newComment.id); ``` ### Arguments @@ -63,14 +62,12 @@ await client.comments.getCommentById(newComment.id) - headers `GetCommentByIdHeadersArg` - Headers of getCommentById method - ### Returns This function returns a value of type `CommentFull`. Returns a full comment object. - ## Update comment Update the message of a comment. @@ -81,8 +78,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-comments-id/). + ```ts -await client.comments.updateCommentById(newReplyComment.id, { message: newMessage } satisfies UpdateCommentByIdRequestBodyArg) +await client.comments.updateCommentById(newReplyComment.id, { + message: newMessage, +} satisfies UpdateCommentByIdRequestBodyArg); ``` ### Arguments @@ -96,14 +96,12 @@ await client.comments.updateCommentById(newReplyComment.id, { message: newMessag - headers `UpdateCommentByIdHeadersArg` - Headers of updateCommentById method - ### Returns This function returns a value of type `CommentFull`. Returns the updated comment object. - ## Remove comment Permanently deletes a comment. @@ -114,8 +112,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-comments-id/). + ```ts -await client.comments.deleteCommentById(newComment.id) +await client.comments.deleteCommentById(newComment.id); ``` ### Arguments @@ -125,14 +124,12 @@ await client.comments.deleteCommentById(newComment.id) - headers `DeleteCommentByIdHeadersArg` - Headers of deleteCommentById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the comment has been deleted. - ## Create comment Adds a comment by the user to a specific file, or @@ -144,8 +141,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-comments/). + ```ts -await client.comments.createComment({ message: message, item: { id: newComment.id, type: "comment" as CreateCommentRequestBodyArgItemFieldTypeField } satisfies CreateCommentRequestBodyArgItemField } satisfies CreateCommentRequestBodyArg) +await client.comments.createComment({ + message: message, + item: { + id: newComment.id, + type: 'comment' as CreateCommentRequestBodyArgItemFieldTypeField, + } satisfies CreateCommentRequestBodyArgItemField, +} satisfies CreateCommentRequestBodyArg); ``` ### Arguments @@ -157,7 +161,6 @@ await client.comments.createComment({ message: message, item: { id: newComment.i - headers `CreateCommentHeadersArg` - Headers of createComment method - ### Returns This function returns a value of type `Comment`. @@ -167,5 +170,3 @@ Returns the newly created comment object. Not all available fields are returned by default. Use the [fields](#param-fields) query parameter to explicitly request any specific fields. - - diff --git a/docs/devicePinners.md b/docs/devicePinners.md index 8c200e4c..014acfc8 100644 --- a/docs/devicePinners.md +++ b/docs/devicePinners.md @@ -1,6 +1,5 @@ # DevicePinnersManager - - [Get device pin](#get-device-pin) - [Remove device pin](#remove-device-pin) - [List enterprise device pins](#list-enterprise-device-pins) @@ -14,7 +13,7 @@ This operation is performed by calling function `getDevicePinnerById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-device-pinners-id/). -*Currently we don't have an example for calling `getDevicePinnerById` in integration tests* +_Currently we don't have an example for calling `getDevicePinnerById` in integration tests_ ### Arguments @@ -23,14 +22,12 @@ See the endpoint docs at - headers `GetDevicePinnerByIdHeadersArg` - Headers of getDevicePinnerById method - ### Returns This function returns a value of type `DevicePinner`. Returns information about a single device pin. - ## Remove device pin Deletes an individual device pin. @@ -40,7 +37,7 @@ This operation is performed by calling function `deleteDevicePinnerById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-device-pinners-id/). -*Currently we don't have an example for calling `deleteDevicePinnerById` in integration tests* +_Currently we don't have an example for calling `deleteDevicePinnerById` in integration tests_ ### Arguments @@ -49,14 +46,12 @@ See the endpoint docs at - headers `DeleteDevicePinnerByIdHeadersArg` - Headers of deleteDevicePinnerById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the pin has been deleted. - ## List enterprise device pins Retrieves all the device pins within an enterprise. @@ -69,7 +64,7 @@ This operation is performed by calling function `getEnterpriseDevicePinners`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-enterprises-id-device-pinners/). -*Currently we don't have an example for calling `getEnterpriseDevicePinners` in integration tests* +_Currently we don't have an example for calling `getEnterpriseDevicePinners` in integration tests_ ### Arguments @@ -80,11 +75,8 @@ See the endpoint docs at - headers `GetEnterpriseDevicePinnersHeadersArg` - Headers of getEnterpriseDevicePinners method - ### Returns This function returns a value of type `DevicePinners`. Returns a list of device pins for a given enterprise. - - diff --git a/docs/emailAliases.md b/docs/emailAliases.md index ee74bee5..f4b51794 100644 --- a/docs/emailAliases.md +++ b/docs/emailAliases.md @@ -1,6 +1,5 @@ # EmailAliasesManager - - [List user's email aliases](#list-users-email-aliases) - [Create email alias](#create-email-alias) - [Remove email alias](#remove-email-alias) @@ -16,8 +15,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users-id-email-aliases/). + ```ts -await client.emailAliases.getUserEmailAliases(newUser.id) +await client.emailAliases.getUserEmailAliases(newUser.id); ``` ### Arguments @@ -27,14 +27,12 @@ await client.emailAliases.getUserEmailAliases(newUser.id) - headers `GetUserEmailAliasesHeadersArg` - Headers of getUserEmailAliases method - ### Returns This function returns a value of type `EmailAliases`. Returns a collection of email aliases. - ## Create email alias Adds a new email alias to a user account.. @@ -45,8 +43,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-users-id-email-aliases/). + ```ts -await client.emailAliases.createUserEmailAlias(newUser.id, { email: newAliasEmail } satisfies CreateUserEmailAliasRequestBodyArg) +await client.emailAliases.createUserEmailAlias(newUser.id, { + email: newAliasEmail, +} satisfies CreateUserEmailAliasRequestBodyArg); ``` ### Arguments @@ -58,14 +59,12 @@ await client.emailAliases.createUserEmailAlias(newUser.id, { email: newAliasEmai - headers `CreateUserEmailAliasHeadersArg` - Headers of createUserEmailAlias method - ### Returns This function returns a value of type `EmailAlias`. Returns the newly created email alias object. - ## Remove email alias Removes an email alias from a user. @@ -76,8 +75,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-users-id-email-aliases-id/). + ```ts -await client.emailAliases.deleteUserEmailAliasById(newUser.id, newAlias.id) +await client.emailAliases.deleteUserEmailAliasById(newUser.id, newAlias.id); ``` ### Arguments @@ -89,11 +89,8 @@ await client.emailAliases.deleteUserEmailAliasById(newUser.id, newAlias.id) - headers `DeleteUserEmailAliasByIdHeadersArg` - Headers of deleteUserEmailAliasById method - ### Returns This function returns a value of type `undefined`. Removes the alias and returns an empty response. - - diff --git a/docs/events.md b/docs/events.md index d4953746..23869961 100644 --- a/docs/events.md +++ b/docs/events.md @@ -1,6 +1,5 @@ # EventsManager - - [List user and enterprise events](#list-user-and-enterprise-events) - [Get events long poll endpoint](#get-events-long-poll-endpoint) @@ -21,7 +20,7 @@ This operation is performed by calling function `getEvents`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-events/). -*Currently we don't have an example for calling `getEvents` in integration tests* +_Currently we don't have an example for calling `getEvents` in integration tests_ ### Arguments @@ -30,7 +29,6 @@ See the endpoint docs at - headers `GetEventsHeadersArg` - Headers of getEvents method - ### Returns This function returns a value of type `Events`. @@ -43,7 +41,6 @@ including a list of event objects. The response includes a chunk, as well as the next `stream_position` that can be queried. - ## Get events long poll endpoint Returns a list of real-time servers that can be used for long-polling updates @@ -85,19 +82,16 @@ This operation is performed by calling function `getEventsWithLongPolling`. See the endpoint docs at [API Reference](https://developer.box.com/reference/options-events/). -*Currently we don't have an example for calling `getEventsWithLongPolling` in integration tests* +_Currently we don't have an example for calling `getEventsWithLongPolling` in integration tests_ ### Arguments - headers `GetEventsWithLongPollingHeadersArg` - Headers of getEventsWithLongPolling method - ### Returns This function returns a value of type `RealtimeServers`. Returns a paginated array of servers that can be used instead of the regular endpoints for long-polling events. - - diff --git a/docs/fileClassifications.md b/docs/fileClassifications.md index 5df5786e..68a38ab7 100644 --- a/docs/fileClassifications.md +++ b/docs/fileClassifications.md @@ -1,6 +1,5 @@ # FileClassificationsManager - - [Get classification on file](#get-classification-on-file) - [Add classification to file](#add-classification-to-file) - [Update classification on file](#update-classification-on-file) @@ -20,16 +19,15 @@ This operation is performed by calling function `getFileMetadataEnterpriseSecuri See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `getFileMetadataEnterpriseSecurityClassification6VmVochwUWo` in integration tests* +_Currently we don't have an example for calling `getFileMetadataEnterpriseSecurityClassification6VmVochwUWo` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `GetFileMetadataEnterpriseSecurityClassification6VmVochwUWoHeadersArg` - Headers of getFileMetadataEnterpriseSecurityClassification6VmVochwUWo method - ### Returns This function returns a value of type `Classification`. @@ -39,7 +37,6 @@ template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Add classification to file Adds a classification to a file by specifying the label of the @@ -54,18 +51,17 @@ This operation is performed by calling function `createFileMetadataEnterpriseSec See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `createFileMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `createFileMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `CreateFileMetadataEnterpriseSecurityClassificationRequestBodyArg` - Request body of createFileMetadataEnterpriseSecurityClassification method - headers `CreateFileMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of createFileMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `Classification`. @@ -73,7 +69,6 @@ This function returns a value of type `Classification`. Returns the classification template instance that was applied to the file. - ## Update classification on file Updates a classification on a file. @@ -87,25 +82,23 @@ This operation is performed by calling function `updateFileMetadataEnterpriseSec See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `updateFileMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `updateFileMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `readonly UpdateFileMetadataEnterpriseSecurityClassificationRequestBodyArg[]` - Request body of updateFileMetadataEnterpriseSecurityClassification method - headers `UpdateFileMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of updateFileMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `Classification`. Returns the updated classification metadata template instance. - ## Remove classification from file Removes any classifications from a file. @@ -119,21 +112,18 @@ This operation is performed by calling function `deleteFileMetadataEnterpriseSec See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `deleteFileMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `deleteFileMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `DeleteFileMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of deleteFileMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the classification is successfully deleted. - - diff --git a/docs/fileMetadata.md b/docs/fileMetadata.md index f0e56a23..994a28e3 100644 --- a/docs/fileMetadata.md +++ b/docs/fileMetadata.md @@ -1,6 +1,5 @@ # FileMetadataManager - - [List metadata instances on file](#list-metadata-instances-on-file) - [Get metadata instance on file](#get-metadata-instance-on-file) - [Create metadata instance on file](#create-metadata-instance-on-file) @@ -17,18 +16,18 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-metadata/). + ```ts -await client.fileMetadata.getFileMetadata(fileId) +await client.fileMetadata.getFileMetadata(fileId); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `GetFileMetadataHeadersArg` - Headers of getFileMetadata method - ### Returns This function returns a value of type `Metadatas`. @@ -38,7 +37,6 @@ Returns all the metadata associated with a file. This API does not support pagination and will therefore always return all of the metadata associated to the file. - ## Get metadata instance on file Retrieves the instance of a metadata template that has been applied to a @@ -50,14 +48,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-metadata-id-id/). + ```ts -await client.fileMetadata.getFileMetadataById(fileId, scope, template) +await client.fileMetadata.getFileMetadataById(fileId, scope, template); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - scope `GetFileMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -65,7 +64,6 @@ await client.fileMetadata.getFileMetadataById(fileId, scope, template) - headers `GetFileMetadataByIdHeadersArg` - Headers of getFileMetadataById method - ### Returns This function returns a value of type `MetadataFull`. @@ -74,7 +72,6 @@ An instance of the metadata template that includes additional "key:value" pairs defined by the user or an application. - ## Create metadata instance on file Applies an instance of a metadata template to a file. @@ -89,14 +86,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id-metadata-id-id/). + ```ts -await client.fileMetadata.createFileMetadataById(fileId, scope, template, data) +await client.fileMetadata.createFileMetadataById(fileId, scope, template, data); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - scope `CreateFileMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -106,7 +104,6 @@ await client.fileMetadata.createFileMetadataById(fileId, scope, template, data) - headers `CreateFileMetadataByIdHeadersArg` - Headers of createFileMetadataById method - ### Returns This function returns a value of type `Metadata`. @@ -114,7 +111,6 @@ This function returns a value of type `Metadata`. Returns the instance of the template that was applied to the file, including the data that was applied to the template. - ## Update metadata instance on file Updates a piece of metadata on a file. @@ -132,14 +128,21 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-metadata-id-id/). + ```ts -await client.fileMetadata.updateFileMetadataById(fileId, scope, template, [{ op: "replace" as UpdateFileMetadataByIdRequestBodyArgOpField, path: "/abc", value: newValue } satisfies UpdateFileMetadataByIdRequestBodyArg]) +await client.fileMetadata.updateFileMetadataById(fileId, scope, template, [ + { + op: 'replace' as UpdateFileMetadataByIdRequestBodyArgOpField, + path: '/abc', + value: newValue, + } satisfies UpdateFileMetadataByIdRequestBodyArg, +]); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - scope `UpdateFileMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -149,7 +152,6 @@ await client.fileMetadata.updateFileMetadataById(fileId, scope, template, [{ op: - headers `UpdateFileMetadataByIdHeadersArg` - Headers of updateFileMetadataById method - ### Returns This function returns a value of type `Metadata`. @@ -157,7 +159,6 @@ This function returns a value of type `Metadata`. Returns the updated metadata template instance, with the custom template data included. - ## Remove metadata instance from file Deletes a piece of file metadata. @@ -168,14 +169,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-metadata-id-id/). + ```ts -await client.fileMetadata.deleteFileMetadataById(fileId, scope, template) +await client.fileMetadata.deleteFileMetadataById(fileId, scope, template); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - scope `DeleteFileMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -183,12 +185,9 @@ await client.fileMetadata.deleteFileMetadataById(fileId, scope, template) - headers `DeleteFileMetadataByIdHeadersArg` - Headers of deleteFileMetadataById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the metadata is successfully deleted. - - diff --git a/docs/fileRequests.md b/docs/fileRequests.md index 65c0b1e4..73866fe3 100644 --- a/docs/fileRequests.md +++ b/docs/fileRequests.md @@ -1,6 +1,5 @@ # FileRequestsManager - - [Get file request](#get-file-request) - [Update file request](#update-file-request) - [Delete file request](#delete-file-request) @@ -15,23 +14,21 @@ This operation is performed by calling function `getFileRequestById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-file-requests-id/). -*Currently we don't have an example for calling `getFileRequestById` in integration tests* +_Currently we don't have an example for calling `getFileRequestById` in integration tests_ ### Arguments - fileRequestId `string` - - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" + - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" - headers `GetFileRequestByIdHeadersArg` - Headers of getFileRequestById method - ### Returns This function returns a value of type `FileRequest`. Returns a file request object. - ## Update file request Updates a file request. This can be used to activate or @@ -42,25 +39,23 @@ This operation is performed by calling function `updateFileRequestById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-file-requests-id/). -*Currently we don't have an example for calling `updateFileRequestById` in integration tests* +_Currently we don't have an example for calling `updateFileRequestById` in integration tests_ ### Arguments - fileRequestId `string` - - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" + - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" - requestBody `FileRequestUpdateRequest` - Request body of updateFileRequestById method - headers `UpdateFileRequestByIdHeadersArg` - Headers of updateFileRequestById method - ### Returns This function returns a value of type `FileRequest`. Returns the updated file request object. - ## Delete file request Deletes a file request permanently. @@ -70,16 +65,15 @@ This operation is performed by calling function `deleteFileRequestById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-file-requests-id/). -*Currently we don't have an example for calling `deleteFileRequestById` in integration tests* +_Currently we don't have an example for calling `deleteFileRequestById` in integration tests_ ### Arguments - fileRequestId `string` - - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" + - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" - headers `DeleteFileRequestByIdHeadersArg` - Headers of deleteFileRequestById method - ### Returns This function returns a value of type `undefined`. @@ -87,7 +81,6 @@ This function returns a value of type `undefined`. Returns an empty response when the file request has been successfully deleted. - ## Copy file request Copies an existing file request that is already present on one folder, @@ -98,22 +91,19 @@ This operation is performed by calling function `createFileRequestCopy`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-file-requests-id-copy/). -*Currently we don't have an example for calling `createFileRequestCopy` in integration tests* +_Currently we don't have an example for calling `createFileRequestCopy` in integration tests_ ### Arguments - fileRequestId `string` - - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" + - The unique identifier that represent a file request. The ID for any file request can be determined by visiting a file request builder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/filerequest/123` the `file_request_id` is `123`. Example: "123" - requestBody `FileRequestCopyRequest` - Request body of createFileRequestCopy method - headers `CreateFileRequestCopyHeadersArg` - Headers of createFileRequestCopy method - ### Returns This function returns a value of type `FileRequest`. Returns updated file request object. - - diff --git a/docs/fileVersionLegalHolds.md b/docs/fileVersionLegalHolds.md index 122b1076..7dc665f1 100644 --- a/docs/fileVersionLegalHolds.md +++ b/docs/fileVersionLegalHolds.md @@ -1,6 +1,5 @@ # FileVersionLegalHoldsManager - - [Get file version legal hold](#get-file-version-legal-hold) - [List file version legal holds](#list-file-version-legal-holds) @@ -14,7 +13,7 @@ This operation is performed by calling function `getFileVersionLegalHoldById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-file-version-legal-holds-id/). -*Currently we don't have an example for calling `getFileVersionLegalHoldById` in integration tests* +_Currently we don't have an example for calling `getFileVersionLegalHoldById` in integration tests_ ### Arguments @@ -23,14 +22,12 @@ See the endpoint docs at - headers `GetFileVersionLegalHoldByIdHeadersArg` - Headers of getFileVersionLegalHoldById method - ### Returns This function returns a value of type `FileVersionLegalHold`. Returns the legal hold policy assignments for the file version. - ## List file version legal holds Get a list of file versions on legal hold for a legal hold @@ -59,7 +56,7 @@ This operation is performed by calling function `getFileVersionLegalHolds`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-file-version-legal-holds/). -*Currently we don't have an example for calling `getFileVersionLegalHolds` in integration tests* +_Currently we don't have an example for calling `getFileVersionLegalHolds` in integration tests_ ### Arguments @@ -68,12 +65,9 @@ See the endpoint docs at - headers `GetFileVersionLegalHoldsHeadersArg` - Headers of getFileVersionLegalHolds method - ### Returns This function returns a value of type `FileVersionLegalHolds`. Returns the list of file version legal holds for a specific legal hold policy. - - diff --git a/docs/fileVersionRetentions.md b/docs/fileVersionRetentions.md index 1a892bcf..94c21794 100644 --- a/docs/fileVersionRetentions.md +++ b/docs/fileVersionRetentions.md @@ -1,6 +1,5 @@ # FileVersionRetentionsManager - - [List file version retentions](#list-file-version-retentions) - [Get retention on file](#get-retention-on-file) @@ -13,7 +12,7 @@ This operation is performed by calling function `getFileVersionRetentions`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-file-version-retentions/). -*Currently we don't have an example for calling `getFileVersionRetentions` in integration tests* +_Currently we don't have an example for calling `getFileVersionRetentions` in integration tests_ ### Arguments @@ -22,14 +21,12 @@ See the endpoint docs at - headers `GetFileVersionRetentionsHeadersArg` - Headers of getFileVersionRetentions method - ### Returns This function returns a value of type `FileVersionRetentions`. Returns a list of all file version retentions for the enterprise. - ## Get retention on file Returns information about a file version retention. @@ -39,7 +36,7 @@ This operation is performed by calling function `getFileVersionRetentionById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-file-version-retentions-id/). -*Currently we don't have an example for calling `getFileVersionRetentionById` in integration tests* +_Currently we don't have an example for calling `getFileVersionRetentionById` in integration tests_ ### Arguments @@ -48,11 +45,8 @@ See the endpoint docs at - headers `GetFileVersionRetentionByIdHeadersArg` - Headers of getFileVersionRetentionById method - ### Returns This function returns a value of type `FileVersionRetention`. Returns a file version retention object. - - diff --git a/docs/fileVersions.md b/docs/fileVersions.md index 5e2d49fd..f68e7d1a 100644 --- a/docs/fileVersions.md +++ b/docs/fileVersions.md @@ -1,6 +1,5 @@ # FileVersionsManager - - [List all file versions](#list-all-file-versions) - [Get file version](#get-file-version) - [Restore file version](#restore-file-version) @@ -19,25 +18,23 @@ This operation is performed by calling function `getFileVersions`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-versions/). -*Currently we don't have an example for calling `getFileVersions` in integration tests* +_Currently we don't have an example for calling `getFileVersions` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - queryParams `GetFileVersionsQueryParamsArg` - Query parameters of getFileVersions method - headers `GetFileVersionsHeadersArg` - Headers of getFileVersions method - ### Returns This function returns a value of type `FileVersions`. Returns an array of past versions for this file. - ## Get file version Retrieve a specific version of a file. @@ -49,12 +46,12 @@ This operation is performed by calling function `getFileVersionById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-versions-id/). -*Currently we don't have an example for calling `getFileVersionById` in integration tests* +_Currently we don't have an example for calling `getFileVersionById` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - fileVersionId `string` - The ID of the file version Example: "1234" - queryParams `GetFileVersionByIdQueryParamsArg` @@ -62,7 +59,6 @@ See the endpoint docs at - headers `GetFileVersionByIdHeadersArg` - Headers of getFileVersionById method - ### Returns This function returns a value of type `FileVersionFull`. @@ -73,7 +69,6 @@ Not all available fields are returned by default. Use the [fields](#param-fields) query parameter to explicitly request any specific fields. - ## Restore file version Restores a specific version of a file after it was deleted. @@ -86,12 +81,12 @@ This operation is performed by calling function `updateFileVersionById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-versions-id/). -*Currently we don't have an example for calling `updateFileVersionById` in integration tests* +_Currently we don't have an example for calling `updateFileVersionById` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - fileVersionId `string` - The ID of the file version Example: "1234" - requestBody `UpdateFileVersionByIdRequestBodyArg` @@ -99,14 +94,12 @@ See the endpoint docs at - headers `UpdateFileVersionByIdHeadersArg` - Headers of updateFileVersionById method - ### Returns This function returns a value of type `FileVersionFull`. Returns a restored file version object. - ## Remove file version Move a file version to the trash. @@ -118,18 +111,17 @@ This operation is performed by calling function `deleteFileVersionById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-versions-id/). -*Currently we don't have an example for calling `deleteFileVersionById` in integration tests* +_Currently we don't have an example for calling `deleteFileVersionById` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - fileVersionId `string` - The ID of the file version Example: "1234" - headers `DeleteFileVersionByIdHeadersArg` - Headers of deleteFileVersionById method - ### Returns This function returns a value of type `undefined`. @@ -137,7 +129,6 @@ This function returns a value of type `undefined`. Returns an empty response when the file has been successfully deleted. - ## Promote file version Promote a specific version of a file. @@ -162,12 +153,12 @@ This operation is performed by calling function `promoteFileVersion`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id-versions-current/). -*Currently we don't have an example for calling `promoteFileVersion` in integration tests* +_Currently we don't have an example for calling `promoteFileVersion` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `PromoteFileVersionRequestBodyArg` - Request body of promoteFileVersion method - queryParams `PromoteFileVersionQueryParamsArg` @@ -175,11 +166,8 @@ See the endpoint docs at - headers `PromoteFileVersionHeadersArg` - Headers of promoteFileVersion method - ### Returns This function returns a value of type `FileVersionFull`. Returns a newly created file version object. - - diff --git a/docs/fileWatermarks.md b/docs/fileWatermarks.md index 905afd67..7dee7a64 100644 --- a/docs/fileWatermarks.md +++ b/docs/fileWatermarks.md @@ -1,6 +1,5 @@ # FileWatermarksManager - - [Get watermark on file](#get-watermark-on-file) - [Apply watermark to file](#apply-watermark-to-file) - [Remove watermark from file](#remove-watermark-from-file) @@ -14,16 +13,15 @@ This operation is performed by calling function `getFileWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-watermark/). -*Currently we don't have an example for calling `getFileWatermark` in integration tests* +_Currently we don't have an example for calling `getFileWatermark` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `GetFileWatermarkHeadersArg` - Headers of getFileWatermark method - ### Returns This function returns a value of type `Watermark`. @@ -31,7 +29,6 @@ This function returns a value of type `Watermark`. Returns an object containing information about the watermark associated for to this file. - ## Apply watermark to file Applies or update a watermark on a file. @@ -41,18 +38,17 @@ This operation is performed by calling function `updateFileWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-watermark/). -*Currently we don't have an example for calling `updateFileWatermark` in integration tests* +_Currently we don't have an example for calling `updateFileWatermark` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `UpdateFileWatermarkRequestBodyArg` - Request body of updateFileWatermark method - headers `UpdateFileWatermarkHeadersArg` - Headers of updateFileWatermark method - ### Returns This function returns a value of type `Watermark`. @@ -61,7 +57,6 @@ Returns an updated watermark if a watermark already existed on this file.Returns a new watermark if no watermark existed on this file yet. - ## Remove watermark from file Removes the watermark from a file. @@ -71,20 +66,17 @@ This operation is performed by calling function `deleteFileWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-watermark/). -*Currently we don't have an example for calling `deleteFileWatermark` in integration tests* +_Currently we don't have an example for calling `deleteFileWatermark` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `DeleteFileWatermarkHeadersArg` - Headers of deleteFileWatermark method - ### Returns This function returns a value of type `undefined`. Removes the watermark and returns an empty response. - - diff --git a/docs/folderClassifications.md b/docs/folderClassifications.md index 25fe3589..21a60cbf 100644 --- a/docs/folderClassifications.md +++ b/docs/folderClassifications.md @@ -1,6 +1,5 @@ # FolderClassificationsManager - - [Get classification on folder](#get-classification-on-folder) - [Add classification to folder](#add-classification-to-folder) - [Update classification on folder](#update-classification-on-folder) @@ -20,16 +19,15 @@ This operation is performed by calling function `getFolderMetadataEnterpriseSecu See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `getFolderMetadataEnterpriseSecurityClassification6VmVochwUWo` in integration tests* +_Currently we don't have an example for calling `getFolderMetadataEnterpriseSecurityClassification6VmVochwUWo` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `GetFolderMetadataEnterpriseSecurityClassification6VmVochwUWoHeadersArg` - Headers of getFolderMetadataEnterpriseSecurityClassification6VmVochwUWo method - ### Returns This function returns a value of type `Classification`. @@ -39,7 +37,6 @@ template, which contains a `Box__Security__Classification__Key` field that lists all the classifications available to this enterprise. - ## Add classification to folder Adds a classification to a folder by specifying the label of the @@ -54,18 +51,17 @@ This operation is performed by calling function `createFolderMetadataEnterpriseS See the endpoint docs at [API Reference](https://developer.box.com/reference/post-folders-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `createFolderMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `createFolderMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `CreateFolderMetadataEnterpriseSecurityClassificationRequestBodyArg` - Request body of createFolderMetadataEnterpriseSecurityClassification method - headers `CreateFolderMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of createFolderMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `Classification`. @@ -73,7 +69,6 @@ This function returns a value of type `Classification`. Returns the classification template instance that was applied to the folder. - ## Update classification on folder Updates a classification on a folder. @@ -87,25 +82,23 @@ This operation is performed by calling function `updateFolderMetadataEnterpriseS See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `updateFolderMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `updateFolderMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `readonly UpdateFolderMetadataEnterpriseSecurityClassificationRequestBodyArg[]` - Request body of updateFolderMetadataEnterpriseSecurityClassification method - headers `UpdateFolderMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of updateFolderMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `Classification`. Returns the updated classification metadata template instance. - ## Remove classification from folder Removes any classifications from a folder. @@ -119,21 +112,18 @@ This operation is performed by calling function `deleteFolderMetadataEnterpriseS See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-folders-id-metadata-enterprise-security-classification-6-vm-vochw-u-wo/). -*Currently we don't have an example for calling `deleteFolderMetadataEnterpriseSecurityClassification` in integration tests* +_Currently we don't have an example for calling `deleteFolderMetadataEnterpriseSecurityClassification` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `DeleteFolderMetadataEnterpriseSecurityClassificationHeadersArg` - Headers of deleteFolderMetadataEnterpriseSecurityClassification method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the classification is successfully deleted. - - diff --git a/docs/folderLocks.md b/docs/folderLocks.md index 4fdfbc19..4fd419c5 100644 --- a/docs/folderLocks.md +++ b/docs/folderLocks.md @@ -1,6 +1,5 @@ # FolderLocksManager - - [List folder locks](#list-folder-locks) - [Create folder lock](#create-folder-lock) - [Delete folder lock](#delete-folder-lock) @@ -18,8 +17,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folder-locks/). + ```ts -await client.folderLocks.getFolderLocks({ folderId: folder.id } satisfies GetFolderLocksQueryParamsArg) +await client.folderLocks.getFolderLocks({ + folderId: folder.id, +} satisfies GetFolderLocksQueryParamsArg); ``` ### Arguments @@ -29,7 +31,6 @@ await client.folderLocks.getFolderLocks({ folderId: folder.id } satisfies GetFol - headers `GetFolderLocksHeadersArg` - Headers of getFolderLocks method - ### Returns This function returns a value of type `FolderLocks`. @@ -37,7 +38,6 @@ This function returns a value of type `FolderLocks`. Returns details for all folder locks applied to the folder, including the lock type and user that applied the lock. - ## Create folder lock Creates a folder lock on a folder, preventing it from being moved and/or @@ -52,8 +52,18 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-folder-locks/). + ```ts -await client.folderLocks.createFolderLock({ folder: { id: folder.id, type: "folder" } satisfies CreateFolderLockRequestBodyArgFolderField, lockedOperations: { move: true, delete: true } satisfies CreateFolderLockRequestBodyArgLockedOperationsField } satisfies CreateFolderLockRequestBodyArg) +await client.folderLocks.createFolderLock({ + folder: { + id: folder.id, + type: 'folder', + } satisfies CreateFolderLockRequestBodyArgFolderField, + lockedOperations: { + move: true, + delete: true, + } satisfies CreateFolderLockRequestBodyArgLockedOperationsField, +} satisfies CreateFolderLockRequestBodyArg); ``` ### Arguments @@ -63,7 +73,6 @@ await client.folderLocks.createFolderLock({ folder: { id: folder.id, type: "fold - headers `CreateFolderLockHeadersArg` - Headers of createFolderLock method - ### Returns This function returns a value of type `FolderLock`. @@ -71,7 +80,6 @@ This function returns a value of type `FolderLock`. Returns the instance of the folder lock that was applied to the folder, including the user that applied the lock and the operations set. - ## Delete folder lock Deletes a folder lock on a given folder. @@ -85,8 +93,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-folder-locks-id/). + ```ts -await client.folderLocks.deleteFolderLockById(folderLock.id) +await client.folderLocks.deleteFolderLockById(folderLock.id); ``` ### Arguments @@ -96,11 +105,8 @@ await client.folderLocks.deleteFolderLockById(folderLock.id) - headers `DeleteFolderLockByIdHeadersArg` - Headers of deleteFolderLockById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the folder lock is successfully deleted. - - diff --git a/docs/folderMetadata.md b/docs/folderMetadata.md index b44558b3..da379a1e 100644 --- a/docs/folderMetadata.md +++ b/docs/folderMetadata.md @@ -1,6 +1,5 @@ # FolderMetadataManager - - [List metadata instances on folder](#list-metadata-instances-on-folder) - [Get metadata instance on folder](#get-metadata-instance-on-folder) - [Create metadata instance on folder](#create-metadata-instance-on-folder) @@ -17,16 +16,15 @@ This operation is performed by calling function `getFolderMetadata`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-metadata/). -*Currently we don't have an example for calling `getFolderMetadata` in integration tests* +_Currently we don't have an example for calling `getFolderMetadata` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `GetFolderMetadataHeadersArg` - Headers of getFolderMetadata method - ### Returns This function returns a value of type `Metadatas`. @@ -36,7 +34,6 @@ Returns all the metadata associated with a folder. This API does not support pagination and will therefore always return all of the metadata associated to the folder. - ## Get metadata instance on folder Retrieves the instance of a metadata template that has been applied to a @@ -47,12 +44,12 @@ This operation is performed by calling function `getFolderMetadataById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-metadata-id-id/). -*Currently we don't have an example for calling `getFolderMetadataById` in integration tests* +_Currently we don't have an example for calling `getFolderMetadataById` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - scope `GetFolderMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -60,7 +57,6 @@ See the endpoint docs at - headers `GetFolderMetadataByIdHeadersArg` - Headers of getFolderMetadataById method - ### Returns This function returns a value of type `Metadata`. @@ -69,7 +65,6 @@ An instance of the metadata template that includes additional "key:value" pairs defined by the user or an application. - ## Create metadata instance on folder Applies an instance of a metadata template to a folder. @@ -87,12 +82,12 @@ This operation is performed by calling function `createFolderMetadataById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-folders-id-metadata-id-id/). -*Currently we don't have an example for calling `createFolderMetadataById` in integration tests* +_Currently we don't have an example for calling `createFolderMetadataById` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - scope `CreateFolderMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -102,7 +97,6 @@ See the endpoint docs at - headers `CreateFolderMetadataByIdHeadersArg` - Headers of createFolderMetadataById method - ### Returns This function returns a value of type `Metadata`. @@ -110,7 +104,6 @@ This function returns a value of type `Metadata`. Returns the instance of the template that was applied to the folder, including the data that was applied to the template. - ## Update metadata instance on folder Updates a piece of metadata on a folder. @@ -127,12 +120,12 @@ This operation is performed by calling function `updateFolderMetadataById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-metadata-id-id/). -*Currently we don't have an example for calling `updateFolderMetadataById` in integration tests* +_Currently we don't have an example for calling `updateFolderMetadataById` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - scope `UpdateFolderMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -142,7 +135,6 @@ See the endpoint docs at - headers `UpdateFolderMetadataByIdHeadersArg` - Headers of updateFolderMetadataById method - ### Returns This function returns a value of type `Metadata`. @@ -150,7 +142,6 @@ This function returns a value of type `Metadata`. Returns the updated metadata template instance, with the custom template data included. - ## Remove metadata instance from folder Deletes a piece of folder metadata. @@ -160,12 +151,12 @@ This operation is performed by calling function `deleteFolderMetadataById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-folders-id-metadata-id-id/). -*Currently we don't have an example for calling `deleteFolderMetadataById` in integration tests* +_Currently we don't have an example for calling `deleteFolderMetadataById` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - scope `DeleteFolderMetadataByIdScopeArg` - The scope of the metadata template Example: "global" - templateKey `string` @@ -173,12 +164,9 @@ See the endpoint docs at - headers `DeleteFolderMetadataByIdHeadersArg` - Headers of deleteFolderMetadataById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the metadata is successfully deleted. - - diff --git a/docs/folderWatermarks.md b/docs/folderWatermarks.md index 0fa7aef7..ec53b87f 100644 --- a/docs/folderWatermarks.md +++ b/docs/folderWatermarks.md @@ -1,6 +1,5 @@ # FolderWatermarksManager - - [Get watermark for folder](#get-watermark-for-folder) - [Apply watermark to folder](#apply-watermark-to-folder) - [Remove watermark from folder](#remove-watermark-from-folder) @@ -14,16 +13,15 @@ This operation is performed by calling function `getFolderWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-watermark/). -*Currently we don't have an example for calling `getFolderWatermark` in integration tests* +_Currently we don't have an example for calling `getFolderWatermark` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `GetFolderWatermarkHeadersArg` - Headers of getFolderWatermark method - ### Returns This function returns a value of type `Watermark`. @@ -31,7 +29,6 @@ This function returns a value of type `Watermark`. Returns an object containing information about the watermark associated for to this folder. - ## Apply watermark to folder Applies or update a watermark on a folder. @@ -41,18 +38,17 @@ This operation is performed by calling function `updateFolderWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-watermark/). -*Currently we don't have an example for calling `updateFolderWatermark` in integration tests* +_Currently we don't have an example for calling `updateFolderWatermark` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `UpdateFolderWatermarkRequestBodyArg` - Request body of updateFolderWatermark method - headers `UpdateFolderWatermarkHeadersArg` - Headers of updateFolderWatermark method - ### Returns This function returns a value of type `Watermark`. @@ -61,7 +57,6 @@ Returns an updated watermark if a watermark already existed on this folder.Returns a new watermark if no watermark existed on this folder yet. - ## Remove watermark from folder Removes the watermark from a folder. @@ -71,21 +66,18 @@ This operation is performed by calling function `deleteFolderWatermark`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-folders-id-watermark/). -*Currently we don't have an example for calling `deleteFolderWatermark` in integration tests* +_Currently we don't have an example for calling `deleteFolderWatermark` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `DeleteFolderWatermarkHeadersArg` - Headers of deleteFolderWatermark method - ### Returns This function returns a value of type `undefined`. An empty response will be returned when the watermark was successfully deleted. - - diff --git a/docs/groups.md b/docs/groups.md index c5f03689..046a68b6 100644 --- a/docs/groups.md +++ b/docs/groups.md @@ -1,6 +1,5 @@ # GroupsManager - - [List groups for enterprise](#list-groups-for-enterprise) - [Create group](#create-group) - [Get group](#get-group) @@ -18,8 +17,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-groups/). + ```ts -await client.groups.getGroups() +await client.groups.getGroups(); ``` ### Arguments @@ -29,7 +29,6 @@ await client.groups.getGroups() - headers `GetGroupsHeadersArg` - Headers of getGroups method - ### Returns This function returns a value of type `Groups`. @@ -37,7 +36,6 @@ This function returns a value of type `Groups`. Returns a collection of group objects. If there are no groups, an empty collection will be returned. - ## Create group Creates a new group of users in an enterprise. Only users with admin @@ -49,8 +47,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-groups/). + ```ts -await client.groups.createGroup({ name: getUuid() } satisfies CreateGroupRequestBodyArg) +await client.groups.createGroup({ + name: getUuid(), +} satisfies CreateGroupRequestBodyArg); ``` ### Arguments @@ -62,14 +63,12 @@ await client.groups.createGroup({ name: getUuid() } satisfies CreateGroupRequest - headers `CreateGroupHeadersArg` - Headers of createGroup method - ### Returns This function returns a value of type `Group`. Returns the new group object. - ## Get group Retrieves information about a group. Only members of this @@ -82,8 +81,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-groups-id/). + ```ts -await client.groups.getGroupById(group.id) +await client.groups.getGroupById(group.id); ``` ### Arguments @@ -95,14 +95,12 @@ await client.groups.getGroupById(group.id) - headers `GetGroupByIdHeadersArg` - Headers of getGroupById method - ### Returns This function returns a value of type `GroupFull`. Returns the group object - ## Update group Updates a specific group. Only admins of this @@ -115,8 +113,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-groups-id/). + ```ts -await client.groups.updateGroupById(group.id, { name: updatedGroupName } satisfies UpdateGroupByIdRequestBodyArg) +await client.groups.updateGroupById(group.id, { + name: updatedGroupName, +} satisfies UpdateGroupByIdRequestBodyArg); ``` ### Arguments @@ -130,14 +131,12 @@ await client.groups.updateGroupById(group.id, { name: updatedGroupName } satisfi - headers `UpdateGroupByIdHeadersArg` - Headers of updateGroupById method - ### Returns This function returns a value of type `GroupFull`. Returns the updated group object. - ## Remove group Permanently deletes a group. Only users with @@ -149,8 +148,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-groups-id/). + ```ts -await client.groups.deleteGroupById(group.id) +await client.groups.deleteGroupById(group.id); ``` ### Arguments @@ -160,12 +160,9 @@ await client.groups.deleteGroupById(group.id) - headers `DeleteGroupByIdHeadersArg` - Headers of deleteGroupById method - ### Returns This function returns a value of type `undefined`. A blank response is returned if the group was successfully deleted. - - diff --git a/docs/integrationMappings.md b/docs/integrationMappings.md index 27999f98..8b8bf61d 100644 --- a/docs/integrationMappings.md +++ b/docs/integrationMappings.md @@ -1,6 +1,5 @@ # IntegrationMappingsManager - - [List Slack integration mappings](#list-slack-integration-mappings) - [Create Slack integration mapping](#create-slack-integration-mapping) - [Update Slack integration mapping](#update-slack-integration-mapping) @@ -18,7 +17,7 @@ This operation is performed by calling function `getIntegrationMappingSlack`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-integration-mappings-slack/). -*Currently we don't have an example for calling `getIntegrationMappingSlack` in integration tests* +_Currently we don't have an example for calling `getIntegrationMappingSlack` in integration tests_ ### Arguments @@ -27,14 +26,12 @@ See the endpoint docs at - headers `GetIntegrationMappingSlackHeadersArg` - Headers of getIntegrationMappingSlack method - ### Returns This function returns a value of type `IntegrationMappings`. Returns a collection of integration mappings - ## Create Slack integration mapping Creates a [Slack integration mapping](https://support.box.com/hc/en-us/articles/4415585987859-Box-as-the-Content-Layer-for-Slack) @@ -48,7 +45,7 @@ This operation is performed by calling function `createIntegrationMappingSlack`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-integration-mappings-slack/). -*Currently we don't have an example for calling `createIntegrationMappingSlack` in integration tests* +_Currently we don't have an example for calling `createIntegrationMappingSlack` in integration tests_ ### Arguments @@ -57,14 +54,12 @@ See the endpoint docs at - headers `CreateIntegrationMappingSlackHeadersArg` - Headers of createIntegrationMappingSlack method - ### Returns This function returns a value of type `IntegrationMapping`. Returns the created integration mapping. - ## Update Slack integration mapping Updates a [Slack integration mapping](https://support.box.com/hc/en-us/articles/4415585987859-Box-as-the-Content-Layer-for-Slack). @@ -78,7 +73,7 @@ This operation is performed by calling function `updateIntegrationMappingSlackBy See the endpoint docs at [API Reference](https://developer.box.com/reference/put-integration-mappings-slack-id/). -*Currently we don't have an example for calling `updateIntegrationMappingSlackById` in integration tests* +_Currently we don't have an example for calling `updateIntegrationMappingSlackById` in integration tests_ ### Arguments @@ -89,19 +84,16 @@ See the endpoint docs at - headers `UpdateIntegrationMappingSlackByIdHeadersArg` - Headers of updateIntegrationMappingSlackById method - ### Returns This function returns a value of type `IntegrationMapping`. Returns the updated integration mapping object. - ## Delete Slack integration mapping Deletes a [Slack integration mapping](https://support.box.com/hc/en-us/articles/4415585987859-Box-as-the-Content-Layer-for-Slack). - You need Admin or Co-Admin role to use this endpoint. @@ -110,7 +102,7 @@ This operation is performed by calling function `deleteIntegrationMappingSlackBy See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-integration-mappings-slack-id/). -*Currently we don't have an example for calling `deleteIntegrationMappingSlackById` in integration tests* +_Currently we don't have an example for calling `deleteIntegrationMappingSlackById` in integration tests_ ### Arguments @@ -119,11 +111,8 @@ See the endpoint docs at - headers `DeleteIntegrationMappingSlackByIdHeadersArg` - Headers of deleteIntegrationMappingSlackById method - ### Returns This function returns a value of type `undefined`. Empty body in response - - diff --git a/docs/invites.md b/docs/invites.md index 538eef1e..0767a29e 100644 --- a/docs/invites.md +++ b/docs/invites.md @@ -1,6 +1,5 @@ # InvitesManager - - [Create user invite](#create-user-invite) - [Get user invite status](#get-user-invite-status) @@ -21,7 +20,7 @@ This operation is performed by calling function `createInvite`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-invites/). -*Currently we don't have an example for calling `createInvite` in integration tests* +_Currently we don't have an example for calling `createInvite` in integration tests_ ### Arguments @@ -32,14 +31,12 @@ See the endpoint docs at - headers `CreateInviteHeadersArg` - Headers of createInvite method - ### Returns This function returns a value of type `Invite`. Returns a new invite object. - ## Get user invite status Returns the status of a user invite. @@ -49,7 +46,7 @@ This operation is performed by calling function `getInviteById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-invites-id/). -*Currently we don't have an example for calling `getInviteById` in integration tests* +_Currently we don't have an example for calling `getInviteById` in integration tests_ ### Arguments @@ -60,11 +57,8 @@ See the endpoint docs at - headers `GetInviteByIdHeadersArg` - Headers of getInviteById method - ### Returns This function returns a value of type `Invite`. Returns an invite object - - diff --git a/docs/legalHoldPolicies.md b/docs/legalHoldPolicies.md index 4d5dff8c..1858bb2f 100644 --- a/docs/legalHoldPolicies.md +++ b/docs/legalHoldPolicies.md @@ -1,6 +1,5 @@ # LegalHoldPoliciesManager - - [List all legal hold policies](#list-all-legal-hold-policies) - [Create legal hold policy](#create-legal-hold-policy) - [Get legal hold policy](#get-legal-hold-policy) @@ -17,7 +16,7 @@ This operation is performed by calling function `getLegalHoldPolicies`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policies/). -*Currently we don't have an example for calling `getLegalHoldPolicies` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicies` in integration tests_ ### Arguments @@ -26,14 +25,12 @@ See the endpoint docs at - headers `GetLegalHoldPoliciesHeadersArg` - Headers of getLegalHoldPolicies method - ### Returns This function returns a value of type `LegalHoldPolicies`. Returns a list of legal hold policies. - ## Create legal hold policy Create a new legal hold policy. @@ -43,7 +40,7 @@ This operation is performed by calling function `createLegalHoldPolicy`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-legal-hold-policies/). -*Currently we don't have an example for calling `createLegalHoldPolicy` in integration tests* +_Currently we don't have an example for calling `createLegalHoldPolicy` in integration tests_ ### Arguments @@ -52,14 +49,12 @@ See the endpoint docs at - headers `CreateLegalHoldPolicyHeadersArg` - Headers of createLegalHoldPolicy method - ### Returns This function returns a value of type `LegalHoldPolicy`. Returns a new legal hold policy object. - ## Get legal hold policy Retrieve a legal hold policy. @@ -69,7 +64,7 @@ This operation is performed by calling function `getLegalHoldPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policies-id/). -*Currently we don't have an example for calling `getLegalHoldPolicyById` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicyById` in integration tests_ ### Arguments @@ -78,14 +73,12 @@ See the endpoint docs at - headers `GetLegalHoldPolicyByIdHeadersArg` - Headers of getLegalHoldPolicyById method - ### Returns This function returns a value of type `LegalHoldPolicy`. Returns a legal hold policy object. - ## Update legal hold policy Update legal hold policy. @@ -95,7 +88,7 @@ This operation is performed by calling function `updateLegalHoldPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-legal-hold-policies-id/). -*Currently we don't have an example for calling `updateLegalHoldPolicyById` in integration tests* +_Currently we don't have an example for calling `updateLegalHoldPolicyById` in integration tests_ ### Arguments @@ -106,14 +99,12 @@ See the endpoint docs at - headers `UpdateLegalHoldPolicyByIdHeadersArg` - Headers of updateLegalHoldPolicyById method - ### Returns This function returns a value of type `LegalHoldPolicy`. Returns a new legal hold policy object. - ## Remove legal hold policy Delete an existing legal hold policy. @@ -126,7 +117,7 @@ This operation is performed by calling function `deleteLegalHoldPolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-legal-hold-policies-id/). -*Currently we don't have an example for calling `deleteLegalHoldPolicyById` in integration tests* +_Currently we don't have an example for calling `deleteLegalHoldPolicyById` in integration tests_ ### Arguments @@ -135,12 +126,9 @@ See the endpoint docs at - headers `DeleteLegalHoldPolicyByIdHeadersArg` - Headers of deleteLegalHoldPolicyById method - ### Returns This function returns a value of type `undefined`. A blank response is returned if the policy was successfully deleted. - - diff --git a/docs/legalHoldPolicyAssignments.md b/docs/legalHoldPolicyAssignments.md index 1fb79964..53e8364b 100644 --- a/docs/legalHoldPolicyAssignments.md +++ b/docs/legalHoldPolicyAssignments.md @@ -1,6 +1,5 @@ # LegalHoldPolicyAssignmentsManager - - [List legal hold policy assignments](#list-legal-hold-policy-assignments) - [Assign legal hold policy](#assign-legal-hold-policy) - [Get legal hold policy assignment](#get-legal-hold-policy-assignment) @@ -17,7 +16,7 @@ This operation is performed by calling function `getLegalHoldPolicyAssignments`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policy-assignments/). -*Currently we don't have an example for calling `getLegalHoldPolicyAssignments` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicyAssignments` in integration tests_ ### Arguments @@ -26,14 +25,12 @@ See the endpoint docs at - headers `GetLegalHoldPolicyAssignmentsHeadersArg` - Headers of getLegalHoldPolicyAssignments method - ### Returns This function returns a value of type `LegalHoldPolicyAssignments`. Returns a list of legal hold policy assignments. - ## Assign legal hold policy Assign a legal hold to a file, file version, folder, or user. @@ -43,7 +40,7 @@ This operation is performed by calling function `createLegalHoldPolicyAssignment See the endpoint docs at [API Reference](https://developer.box.com/reference/post-legal-hold-policy-assignments/). -*Currently we don't have an example for calling `createLegalHoldPolicyAssignment` in integration tests* +_Currently we don't have an example for calling `createLegalHoldPolicyAssignment` in integration tests_ ### Arguments @@ -52,14 +49,12 @@ See the endpoint docs at - headers `CreateLegalHoldPolicyAssignmentHeadersArg` - Headers of createLegalHoldPolicyAssignment method - ### Returns This function returns a value of type `LegalHoldPolicyAssignment`. Returns a new legal hold policy assignment. - ## Get legal hold policy assignment Retrieve a legal hold policy assignment. @@ -69,7 +64,7 @@ This operation is performed by calling function `getLegalHoldPolicyAssignmentByI See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policy-assignments-id/). -*Currently we don't have an example for calling `getLegalHoldPolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicyAssignmentById` in integration tests_ ### Arguments @@ -78,14 +73,12 @@ See the endpoint docs at - headers `GetLegalHoldPolicyAssignmentByIdHeadersArg` - Headers of getLegalHoldPolicyAssignmentById method - ### Returns This function returns a value of type `LegalHoldPolicyAssignment`. Returns a legal hold policy object. - ## Unassign legal hold policy Remove a legal hold from an item. @@ -98,7 +91,7 @@ This operation is performed by calling function `deleteLegalHoldPolicyAssignment See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-legal-hold-policy-assignments-id/). -*Currently we don't have an example for calling `deleteLegalHoldPolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `deleteLegalHoldPolicyAssignmentById` in integration tests_ ### Arguments @@ -107,7 +100,6 @@ See the endpoint docs at - headers `DeleteLegalHoldPolicyAssignmentByIdHeadersArg` - Headers of deleteLegalHoldPolicyAssignmentById method - ### Returns This function returns a value of type `undefined`. @@ -115,7 +107,6 @@ This function returns a value of type `undefined`. A blank response is returned if the assignment was successfully deleted. - ## List current file versions for legal hold policy assignment Get a list of current file versions for a legal hold @@ -140,7 +131,7 @@ This operation is performed by calling function `getLegalHoldPolicyAssignmentFil See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policy-assignments-id-files-on-hold/). -*Currently we don't have an example for calling `getLegalHoldPolicyAssignmentFileOnHold` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicyAssignmentFileOnHold` in integration tests_ ### Arguments @@ -151,7 +142,6 @@ See the endpoint docs at - headers `GetLegalHoldPolicyAssignmentFileOnHoldHeadersArg` - Headers of getLegalHoldPolicyAssignmentFileOnHold method - ### Returns This function returns a value of type `FileVersionLegalHolds`. @@ -159,7 +149,6 @@ This function returns a value of type `FileVersionLegalHolds`. Returns the list of current file versions held under legal hold for a specific legal hold policy assignment. - ## List previous file versions for legal hold policy assignment Get a list of previous file versions for a legal hold @@ -184,7 +173,7 @@ This operation is performed by calling function `getLegalHoldPolicyAssignmentFil See the endpoint docs at [API Reference](https://developer.box.com/reference/get-legal-hold-policy-assignments-id-file-versions-on-hold/). -*Currently we don't have an example for calling `getLegalHoldPolicyAssignmentFileVersionOnHold` in integration tests* +_Currently we don't have an example for calling `getLegalHoldPolicyAssignmentFileVersionOnHold` in integration tests_ ### Arguments @@ -195,12 +184,9 @@ See the endpoint docs at - headers `GetLegalHoldPolicyAssignmentFileVersionOnHoldHeadersArg` - Headers of getLegalHoldPolicyAssignmentFileVersionOnHold method - ### Returns This function returns a value of type `FileVersionLegalHolds`. Returns the list of previous file versions held under legal hold for a specific legal hold policy assignment. - - diff --git a/docs/listCollaborations.md b/docs/listCollaborations.md index 58388f54..684a8174 100644 --- a/docs/listCollaborations.md +++ b/docs/listCollaborations.md @@ -1,6 +1,5 @@ # ListCollaborationsManager - - [List file collaborations](#list-file-collaborations) - [List folder collaborations](#list-folder-collaborations) - [List pending collaborations](#list-pending-collaborations) @@ -17,18 +16,17 @@ This operation is performed by calling function `getFileCollaborations`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-collaborations/). -*Currently we don't have an example for calling `getFileCollaborations` in integration tests* +_Currently we don't have an example for calling `getFileCollaborations` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - queryParams `GetFileCollaborationsQueryParamsArg` - Query parameters of getFileCollaborations method - headers `GetFileCollaborationsHeadersArg` - Headers of getFileCollaborations method - ### Returns This function returns a value of type `Collaborations`. @@ -40,7 +38,6 @@ This list includes pending collaborations, for which the `status` is set to `pending`, indicating invitations that have been sent but not yet accepted. - ## List folder collaborations Retrieves a list of pending and active collaborations for a @@ -52,18 +49,17 @@ This operation is performed by calling function `getFolderCollaborations`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-collaborations/). -*Currently we don't have an example for calling `getFolderCollaborations` in integration tests* +_Currently we don't have an example for calling `getFolderCollaborations` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. Example: "12345" - queryParams `GetFolderCollaborationsQueryParamsArg` - Query parameters of getFolderCollaborations method - headers `GetFolderCollaborationsHeadersArg` - Headers of getFolderCollaborations method - ### Returns This function returns a value of type `Collaborations`. @@ -75,7 +71,6 @@ This list includes pending collaborations, for which the `status` is set to `pending`, indicating invitations that have been sent but not yet accepted. - ## List pending collaborations Retrieves all pending collaboration invites for this user. @@ -85,7 +80,7 @@ This operation is performed by calling function `getCollaborations`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaborations/). -*Currently we don't have an example for calling `getCollaborations` in integration tests* +_Currently we don't have an example for calling `getCollaborations` in integration tests_ ### Arguments @@ -94,7 +89,6 @@ See the endpoint docs at - headers `GetCollaborationsHeadersArg` - Headers of getCollaborations method - ### Returns This function returns a value of type `Collaborations`. @@ -104,7 +98,6 @@ Returns a collection of pending collaboration objects. If the user has no pending collaborations, the collection will be empty. - ## List group collaborations Retrieves all the collaborations for a group. The user @@ -118,7 +111,7 @@ This operation is performed by calling function `getGroupCollaborations`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-groups-id-collaborations/). -*Currently we don't have an example for calling `getGroupCollaborations` in integration tests* +_Currently we don't have an example for calling `getGroupCollaborations` in integration tests_ ### Arguments @@ -129,12 +122,9 @@ See the endpoint docs at - headers `GetGroupCollaborationsHeadersArg` - Headers of getGroupCollaborations method - ### Returns This function returns a value of type `Collaborations`. Returns a collection of collaboration objects. If there are no collaborations, an empty collection will be returned. - - diff --git a/docs/memberships.md b/docs/memberships.md index 3516e9c7..e1ff85ed 100644 --- a/docs/memberships.md +++ b/docs/memberships.md @@ -1,6 +1,5 @@ # MembershipsManager - - [List user's groups](#list-users-groups) - [List members of group](#list-members-of-group) - [Add user to group](#add-user-to-group) @@ -20,8 +19,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users-id-memberships/). + ```ts -await client.memberships.getUserMemberships(user.id) +await client.memberships.getUserMemberships(user.id); ``` ### Arguments @@ -33,7 +33,6 @@ await client.memberships.getUserMemberships(user.id) - headers `GetUserMembershipsHeadersArg` - Headers of getUserMemberships method - ### Returns This function returns a value of type `GroupMemberships`. @@ -41,7 +40,6 @@ This function returns a value of type `GroupMemberships`. Returns a collection of membership objects. If there are no memberships, an empty collection will be returned. - ## List members of group Retrieves all the members for a group. Only members of this @@ -54,8 +52,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-groups-id-memberships/). + ```ts -await client.memberships.getGroupMemberships(group.id) +await client.memberships.getGroupMemberships(group.id); ``` ### Arguments @@ -67,7 +66,6 @@ await client.memberships.getGroupMemberships(group.id) - headers `GetGroupMembershipsHeadersArg` - Headers of getGroupMemberships method - ### Returns This function returns a value of type `GroupMemberships`. @@ -75,7 +73,6 @@ This function returns a value of type `GroupMemberships`. Returns a collection of membership objects. If there are no memberships, an empty collection will be returned. - ## Add user to group Creates a group membership. Only users with @@ -87,8 +84,12 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-group-memberships/). + ```ts -await client.memberships.createGroupMembership({ user: user, group: group } satisfies CreateGroupMembershipRequestBodyArg) +await client.memberships.createGroupMembership({ + user: user, + group: group, +} satisfies CreateGroupMembershipRequestBodyArg); ``` ### Arguments @@ -100,14 +101,12 @@ await client.memberships.createGroupMembership({ user: user, group: group } sati - headers `CreateGroupMembershipHeadersArg` - Headers of createGroupMembership method - ### Returns This function returns a value of type `GroupMembership`. Returns a new group membership object. - ## Get group membership Retrieves a specific group membership. Only admins of this @@ -120,8 +119,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-group-memberships-id/). + ```ts -await client.memberships.getGroupMembershipById(groupMembership.id) +await client.memberships.getGroupMembershipById(groupMembership.id); ``` ### Arguments @@ -133,14 +133,12 @@ await client.memberships.getGroupMembershipById(groupMembership.id) - headers `GetGroupMembershipByIdHeadersArg` - Headers of getGroupMembershipById method - ### Returns This function returns a value of type `GroupMembership`. Returns the group membership object. - ## Update group membership Updates a user's group membership. Only admins of this @@ -153,8 +151,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-group-memberships-id/). + ```ts -await client.memberships.updateGroupMembershipById(groupMembership.id, { role: "admin" as UpdateGroupMembershipByIdRequestBodyArgRoleField } satisfies UpdateGroupMembershipByIdRequestBodyArg) +await client.memberships.updateGroupMembershipById(groupMembership.id, { + role: 'admin' as UpdateGroupMembershipByIdRequestBodyArgRoleField, +} satisfies UpdateGroupMembershipByIdRequestBodyArg); ``` ### Arguments @@ -168,14 +169,12 @@ await client.memberships.updateGroupMembershipById(groupMembership.id, { role: " - headers `UpdateGroupMembershipByIdHeadersArg` - Headers of updateGroupMembershipById method - ### Returns This function returns a value of type `GroupMembership`. Returns a new group membership object. - ## Remove user from group Deletes a specific group membership. Only admins of this @@ -188,8 +187,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-group-memberships-id/). + ```ts -await client.memberships.deleteGroupMembershipById(groupMembership.id) +await client.memberships.deleteGroupMembershipById(groupMembership.id); ``` ### Arguments @@ -199,12 +199,9 @@ await client.memberships.deleteGroupMembershipById(groupMembership.id) - headers `DeleteGroupMembershipByIdHeadersArg` - Headers of deleteGroupMembershipById method - ### Returns This function returns a value of type `undefined`. A blank response is returned if the membership was successfully deleted. - - diff --git a/docs/metadataCascadePolicies.md b/docs/metadataCascadePolicies.md index aeacd192..7eea9a8f 100644 --- a/docs/metadataCascadePolicies.md +++ b/docs/metadataCascadePolicies.md @@ -1,6 +1,5 @@ # MetadataCascadePoliciesManager - - [List metadata cascade policies](#list-metadata-cascade-policies) - [Create metadata cascade policy](#create-metadata-cascade-policy) - [Get metadata cascade policy](#get-metadata-cascade-policy) @@ -18,7 +17,7 @@ This operation is performed by calling function `getMetadataCascadePolicies`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-cascade-policies/). -*Currently we don't have an example for calling `getMetadataCascadePolicies` in integration tests* +_Currently we don't have an example for calling `getMetadataCascadePolicies` in integration tests_ ### Arguments @@ -27,14 +26,12 @@ See the endpoint docs at - headers `GetMetadataCascadePoliciesHeadersArg` - Headers of getMetadataCascadePolicies method - ### Returns This function returns a value of type `MetadataCascadePolicies`. Returns a list of metadata cascade policies - ## Create metadata cascade policy Creates a new metadata cascade policy that applies a given @@ -49,7 +46,7 @@ This operation is performed by calling function `createMetadataCascadePolicy`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-metadata-cascade-policies/). -*Currently we don't have an example for calling `createMetadataCascadePolicy` in integration tests* +_Currently we don't have an example for calling `createMetadataCascadePolicy` in integration tests_ ### Arguments @@ -58,14 +55,12 @@ See the endpoint docs at - headers `CreateMetadataCascadePolicyHeadersArg` - Headers of createMetadataCascadePolicy method - ### Returns This function returns a value of type `MetadataCascadePolicy`. Returns a new of metadata cascade policy - ## Get metadata cascade policy Retrieve a specific metadata cascade policy assigned to a folder. @@ -75,7 +70,7 @@ This operation is performed by calling function `getMetadataCascadePolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-cascade-policies-id/). -*Currently we don't have an example for calling `getMetadataCascadePolicyById` in integration tests* +_Currently we don't have an example for calling `getMetadataCascadePolicyById` in integration tests_ ### Arguments @@ -84,14 +79,12 @@ See the endpoint docs at - headers `GetMetadataCascadePolicyByIdHeadersArg` - Headers of getMetadataCascadePolicyById method - ### Returns This function returns a value of type `MetadataCascadePolicy`. Returns a metadata cascade policy - ## Remove metadata cascade policy Deletes a metadata cascade policy. @@ -101,7 +94,7 @@ This operation is performed by calling function `deleteMetadataCascadePolicyById See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-metadata-cascade-policies-id/). -*Currently we don't have an example for calling `deleteMetadataCascadePolicyById` in integration tests* +_Currently we don't have an example for calling `deleteMetadataCascadePolicyById` in integration tests_ ### Arguments @@ -110,7 +103,6 @@ See the endpoint docs at - headers `DeleteMetadataCascadePolicyByIdHeadersArg` - Headers of deleteMetadataCascadePolicyById method - ### Returns This function returns a value of type `undefined`. @@ -118,7 +110,6 @@ This function returns a value of type `undefined`. Returns an empty response when the policy is successfully deleted. - ## Force-apply metadata cascade policy to folder Force the metadata on a folder with a metadata cascade policy to be applied to @@ -131,7 +122,7 @@ This operation is performed by calling function `createMetadataCascadePolicyAppl See the endpoint docs at [API Reference](https://developer.box.com/reference/post-metadata-cascade-policies-id-apply/). -*Currently we don't have an example for calling `createMetadataCascadePolicyApply` in integration tests* +_Currently we don't have an example for calling `createMetadataCascadePolicyApply` in integration tests_ ### Arguments @@ -142,7 +133,6 @@ See the endpoint docs at - headers `CreateMetadataCascadePolicyApplyHeadersArg` - Headers of createMetadataCascadePolicyApply method - ### Returns This function returns a value of type `undefined`. @@ -153,5 +143,3 @@ cascade operation will be performed asynchronously. The API call will return directly, before the cascade operation is complete. There is currently no API to check for the status of this operation. - - diff --git a/docs/metadataTemplates.md b/docs/metadataTemplates.md index b1f6094b..4c10d530 100644 --- a/docs/metadataTemplates.md +++ b/docs/metadataTemplates.md @@ -1,6 +1,5 @@ # MetadataTemplatesManager - - [Find metadata template by instance ID](#find-metadata-template-by-instance-id) - [Get metadata template by name](#get-metadata-template-by-name) - [Update metadata template](#update-metadata-template) @@ -20,7 +19,7 @@ This operation is performed by calling function `getMetadataTemplates`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates/). -*Currently we don't have an example for calling `getMetadataTemplates` in integration tests* +_Currently we don't have an example for calling `getMetadataTemplates` in integration tests_ ### Arguments @@ -29,7 +28,6 @@ See the endpoint docs at - headers `GetMetadataTemplatesHeadersArg` - Headers of getMetadataTemplates method - ### Returns This function returns a value of type `MetadataTemplates`. @@ -37,7 +35,6 @@ This function returns a value of type `MetadataTemplates`. Returns a list containing the 1 metadata template that matches the instance ID. - ## Get metadata template by name Retrieves a metadata template by its `scope` and `templateKey` values. @@ -51,8 +48,12 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates-id-id-schema/). + ```ts -await client.metadataTemplates.getMetadataTemplateSchema("enterprise" as GetMetadataTemplateSchemaScopeArg, template.templateKey) +await client.metadataTemplates.getMetadataTemplateSchema( + 'enterprise' as GetMetadataTemplateSchemaScopeArg, + template.templateKey +); ``` ### Arguments @@ -64,7 +65,6 @@ await client.metadataTemplates.getMetadataTemplateSchema("enterprise" as GetMeta - headers `GetMetadataTemplateSchemaHeadersArg` - Headers of getMetadataTemplateSchema method - ### Returns This function returns a value of type `MetadataTemplate`. @@ -72,7 +72,6 @@ This function returns a value of type `MetadataTemplate`. Returns the metadata template matching the `scope` and `template` name. - ## Update metadata template Updates a metadata template. @@ -88,7 +87,7 @@ This operation is performed by calling function `updateMetadataTemplateSchema`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-metadata-templates-id-id-schema/). -*Currently we don't have an example for calling `updateMetadataTemplateSchema` in integration tests* +_Currently we don't have an example for calling `updateMetadataTemplateSchema` in integration tests_ ### Arguments @@ -101,7 +100,6 @@ See the endpoint docs at - headers `UpdateMetadataTemplateSchemaHeadersArg` - Headers of updateMetadataTemplateSchema method - ### Returns This function returns a value of type `MetadataTemplate`. @@ -109,7 +107,6 @@ This function returns a value of type `MetadataTemplate`. Returns the updated metadata template, with the custom template data included. - ## Remove metadata template Delete a metadata template and its instances. @@ -121,8 +118,12 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-metadata-templates-id-id-schema/). + ```ts -await client.metadataTemplates.deleteMetadataTemplateSchema("enterprise" as DeleteMetadataTemplateSchemaScopeArg, template.templateKey) +await client.metadataTemplates.deleteMetadataTemplateSchema( + 'enterprise' as DeleteMetadataTemplateSchemaScopeArg, + template.templateKey +); ``` ### Arguments @@ -134,7 +135,6 @@ await client.metadataTemplates.deleteMetadataTemplateSchema("enterprise" as Dele - headers `DeleteMetadataTemplateSchemaHeadersArg` - Headers of deleteMetadataTemplateSchema method - ### Returns This function returns a value of type `undefined`. @@ -142,7 +142,6 @@ This function returns a value of type `undefined`. Returns an empty response when the metadata template is successfully deleted. - ## Get metadata template by ID Retrieves a metadata template by its ID. @@ -153,8 +152,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates-id/). + ```ts -await client.metadataTemplates.getMetadataTemplateById(template.id) +await client.metadataTemplates.getMetadataTemplateById(template.id); ``` ### Arguments @@ -164,14 +164,12 @@ await client.metadataTemplates.getMetadataTemplateById(template.id) - headers `GetMetadataTemplateByIdHeadersArg` - Headers of getMetadataTemplateById method - ### Returns This function returns a value of type `MetadataTemplate`. Returns the metadata template that matches the ID. - ## List all global metadata templates Used to retrieve all generic, global metadata templates available to all @@ -183,8 +181,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates-global/). + ```ts -await client.metadataTemplates.getMetadataTemplateGlobal() +await client.metadataTemplates.getMetadataTemplateGlobal(); ``` ### Arguments @@ -194,7 +193,6 @@ await client.metadataTemplates.getMetadataTemplateGlobal() - headers `GetMetadataTemplateGlobalHeadersArg` - Headers of getMetadataTemplateGlobal method - ### Returns This function returns a value of type `MetadataTemplates`. @@ -202,7 +200,6 @@ This function returns a value of type `MetadataTemplates`. Returns all of the metadata templates available to all enterprises and their corresponding schema. - ## List all metadata templates for enterprise Used to retrieve all metadata templates created to be used specifically within @@ -214,8 +211,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-templates-enterprise/). + ```ts -await client.metadataTemplates.getMetadataTemplateEnterprise() +await client.metadataTemplates.getMetadataTemplateEnterprise(); ``` ### Arguments @@ -225,7 +223,6 @@ await client.metadataTemplates.getMetadataTemplateEnterprise() - headers `GetMetadataTemplateEnterpriseHeadersArg` - Headers of getMetadataTemplateEnterprise method - ### Returns This function returns a value of type `MetadataTemplates`. @@ -233,7 +230,6 @@ This function returns a value of type `MetadataTemplates`. Returns all of the metadata templates within an enterprise and their corresponding schema. - ## Create metadata template Creates a new metadata template that can be applied to @@ -245,8 +241,14 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-metadata-templates-schema/). + ```ts -await client.metadataTemplates.createMetadataTemplateSchema({ scope: "enterprise", displayName: templateKey, templateKey: templateKey, fields: [{ type: "string", key: "testName", displayName: "testName" }] } satisfies CreateMetadataTemplateSchemaRequestBodyArg) +await client.metadataTemplates.createMetadataTemplateSchema({ + scope: 'enterprise', + displayName: templateKey, + templateKey: templateKey, + fields: [{ type: 'string', key: 'testName', displayName: 'testName' }], +} satisfies CreateMetadataTemplateSchemaRequestBodyArg); ``` ### Arguments @@ -256,11 +258,8 @@ await client.metadataTemplates.createMetadataTemplateSchema({ scope: "enterprise - headers `CreateMetadataTemplateSchemaHeadersArg` - Headers of createMetadataTemplateSchema method - ### Returns This function returns a value of type `MetadataTemplate`. The schema representing the metadata template created. - - diff --git a/docs/recentItems.md b/docs/recentItems.md index 77f36bd6..05e10ee2 100644 --- a/docs/recentItems.md +++ b/docs/recentItems.md @@ -1,6 +1,5 @@ # RecentItemsManager - - [List recently accessed items](#list-recently-accessed-items) ## List recently accessed items @@ -15,8 +14,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-recent-items/). + ```ts -await client.recentItems.getRecentItems() +await client.recentItems.getRecentItems(); ``` ### Arguments @@ -26,11 +26,8 @@ await client.recentItems.getRecentItems() - headers `GetRecentItemsHeadersArg` - Headers of getRecentItems method - ### Returns This function returns a value of type `RecentItems`. Returns a list recent items access by a user. - - diff --git a/docs/retentionPolicies.md b/docs/retentionPolicies.md index 207c5d9d..ec26d4b9 100644 --- a/docs/retentionPolicies.md +++ b/docs/retentionPolicies.md @@ -1,6 +1,5 @@ # RetentionPoliciesManager - - [List retention policies](#list-retention-policies) - [Create retention policy](#create-retention-policy) - [Get retention policy](#get-retention-policy) @@ -17,8 +16,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policies/). + ```ts -await client.retentionPolicies.getRetentionPolicies() +await client.retentionPolicies.getRetentionPolicies(); ``` ### Arguments @@ -28,14 +28,12 @@ await client.retentionPolicies.getRetentionPolicies() - headers `GetRetentionPoliciesHeadersArg` - Headers of getRetentionPolicies method - ### Returns This function returns a value of type `RetentionPolicies`. Returns a list retention policies in the enterprise. - ## Create retention policy Creates a retention policy. @@ -46,8 +44,20 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-retention-policies/). + ```ts -await client.retentionPolicies.createRetentionPolicy({ policyName: retentionPolicyName, policyType: "finite" as CreateRetentionPolicyRequestBodyArgPolicyTypeField, areOwnersNotified: true, canOwnerExtendRetention: true, description: retentionDescription, dispositionAction: "remove_retention" as CreateRetentionPolicyRequestBodyArgDispositionActionField, retentionLength: "1", retentionType: "modifiable" as CreateRetentionPolicyRequestBodyArgRetentionTypeField } satisfies CreateRetentionPolicyRequestBodyArg) +await client.retentionPolicies.createRetentionPolicy({ + policyName: retentionPolicyName, + policyType: 'finite' as CreateRetentionPolicyRequestBodyArgPolicyTypeField, + areOwnersNotified: true, + canOwnerExtendRetention: true, + description: retentionDescription, + dispositionAction: + 'remove_retention' as CreateRetentionPolicyRequestBodyArgDispositionActionField, + retentionLength: '1', + retentionType: + 'modifiable' as CreateRetentionPolicyRequestBodyArgRetentionTypeField, +} satisfies CreateRetentionPolicyRequestBodyArg); ``` ### Arguments @@ -57,14 +67,12 @@ await client.retentionPolicies.createRetentionPolicy({ policyName: retentionPoli - headers `CreateRetentionPolicyHeadersArg` - Headers of createRetentionPolicy method - ### Returns This function returns a value of type `RetentionPolicy`. Returns a new retention policy object. - ## Get retention policy Retrieves a retention policy. @@ -75,8 +83,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policies-id/). + ```ts -await client.retentionPolicies.getRetentionPolicyById(retentionPolicy.id) +await client.retentionPolicies.getRetentionPolicyById(retentionPolicy.id); ``` ### Arguments @@ -88,14 +97,12 @@ await client.retentionPolicies.getRetentionPolicyById(retentionPolicy.id) - headers `GetRetentionPolicyByIdHeadersArg` - Headers of getRetentionPolicyById method - ### Returns This function returns a value of type `RetentionPolicy`. Returns the retention policy object. - ## Update retention policy Updates a retention policy. @@ -106,8 +113,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-retention-policies-id/). + ```ts -await client.retentionPolicies.updateRetentionPolicyById(retentionPolicy.id, { policyName: updatedRetentionPolicyName } satisfies UpdateRetentionPolicyByIdRequestBodyArg) +await client.retentionPolicies.updateRetentionPolicyById(retentionPolicy.id, { + policyName: updatedRetentionPolicyName, +} satisfies UpdateRetentionPolicyByIdRequestBodyArg); ``` ### Arguments @@ -119,14 +129,12 @@ await client.retentionPolicies.updateRetentionPolicyById(retentionPolicy.id, { p - headers `UpdateRetentionPolicyByIdHeadersArg` - Headers of updateRetentionPolicyById method - ### Returns This function returns a value of type `RetentionPolicy`. Returns the updated retention policy object. - ## Delete retention policy Permanently deletes a retention policy. @@ -137,8 +145,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-retention-policies-id/). + ```ts -await client.retentionPolicies.deleteRetentionPolicyById(retentionPolicy.id) +await client.retentionPolicies.deleteRetentionPolicyById(retentionPolicy.id); ``` ### Arguments @@ -148,11 +157,8 @@ await client.retentionPolicies.deleteRetentionPolicyById(retentionPolicy.id) - headers `DeleteRetentionPolicyByIdHeadersArg` - Headers of deleteRetentionPolicyById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the policy has been deleted. - - diff --git a/docs/retentionPolicyAssignments.md b/docs/retentionPolicyAssignments.md index ee2329e9..1dbe6219 100644 --- a/docs/retentionPolicyAssignments.md +++ b/docs/retentionPolicyAssignments.md @@ -1,6 +1,5 @@ # RetentionPolicyAssignmentsManager - - [List retention policy assignments](#list-retention-policy-assignments) - [Assign retention policy](#assign-retention-policy) - [Get retention policy assignment](#get-retention-policy-assignment) @@ -18,7 +17,7 @@ This operation is performed by calling function `getRetentionPolicyAssignments`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policies-id-assignments/). -*Currently we don't have an example for calling `getRetentionPolicyAssignments` in integration tests* +_Currently we don't have an example for calling `getRetentionPolicyAssignments` in integration tests_ ### Arguments @@ -29,7 +28,6 @@ See the endpoint docs at - headers `GetRetentionPolicyAssignmentsHeadersArg` - Headers of getRetentionPolicyAssignments method - ### Returns This function returns a value of type `RetentionPolicyAssignments`. @@ -37,7 +35,6 @@ This function returns a value of type `RetentionPolicyAssignments`. Returns a list of the retention policy assignments associated with the specified retention policy. - ## Assign retention policy Assigns a retention policy to an item. @@ -47,7 +44,7 @@ This operation is performed by calling function `createRetentionPolicyAssignment See the endpoint docs at [API Reference](https://developer.box.com/reference/post-retention-policy-assignments/). -*Currently we don't have an example for calling `createRetentionPolicyAssignment` in integration tests* +_Currently we don't have an example for calling `createRetentionPolicyAssignment` in integration tests_ ### Arguments @@ -56,14 +53,12 @@ See the endpoint docs at - headers `CreateRetentionPolicyAssignmentHeadersArg` - Headers of createRetentionPolicyAssignment method - ### Returns This function returns a value of type `RetentionPolicyAssignment`. Returns a new retention policy assignment object. - ## Get retention policy assignment Retrieves a retention policy assignment @@ -73,7 +68,7 @@ This operation is performed by calling function `getRetentionPolicyAssignmentByI See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policy-assignments-id/). -*Currently we don't have an example for calling `getRetentionPolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `getRetentionPolicyAssignmentById` in integration tests_ ### Arguments @@ -84,14 +79,12 @@ See the endpoint docs at - headers `GetRetentionPolicyAssignmentByIdHeadersArg` - Headers of getRetentionPolicyAssignmentById method - ### Returns This function returns a value of type `RetentionPolicyAssignment`. Returns the retention policy assignment object. - ## Remove retention policy assignment Removes a retention policy assignment @@ -102,7 +95,7 @@ This operation is performed by calling function `deleteRetentionPolicyAssignment See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-retention-policy-assignments-id/). -*Currently we don't have an example for calling `deleteRetentionPolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `deleteRetentionPolicyAssignmentById` in integration tests_ ### Arguments @@ -111,7 +104,6 @@ See the endpoint docs at - headers `DeleteRetentionPolicyAssignmentByIdHeadersArg` - Headers of deleteRetentionPolicyAssignmentById method - ### Returns This function returns a value of type `undefined`. @@ -119,7 +111,6 @@ This function returns a value of type `undefined`. Returns an empty response when the policy assignment is successfully deleted. - ## Get files under retention Returns a list of files under retention for a retention policy assignment. @@ -129,7 +120,7 @@ This operation is performed by calling function `getRetentionPolicyAssignmentFil See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policy-assignments-id-files-under-retention/). -*Currently we don't have an example for calling `getRetentionPolicyAssignmentFileUnderRetention` in integration tests* +_Currently we don't have an example for calling `getRetentionPolicyAssignmentFileUnderRetention` in integration tests_ ### Arguments @@ -140,7 +131,6 @@ See the endpoint docs at - headers `GetRetentionPolicyAssignmentFileUnderRetentionHeadersArg` - Headers of getRetentionPolicyAssignmentFileUnderRetention method - ### Returns This function returns a value of type `FilesUnderRetention`. @@ -148,7 +138,6 @@ This function returns a value of type `FilesUnderRetention`. Returns a list of files under retention that are associated with the specified retention policy assignment. - ## Get file versions under retention Returns a list of file versions under retention for a retention policy @@ -159,7 +148,7 @@ This operation is performed by calling function `getRetentionPolicyAssignmentFil See the endpoint docs at [API Reference](https://developer.box.com/reference/get-retention-policy-assignments-id-file-versions-under-retention/). -*Currently we don't have an example for calling `getRetentionPolicyAssignmentFileVersionUnderRetention` in integration tests* +_Currently we don't have an example for calling `getRetentionPolicyAssignmentFileVersionUnderRetention` in integration tests_ ### Arguments @@ -170,12 +159,9 @@ See the endpoint docs at - headers `GetRetentionPolicyAssignmentFileVersionUnderRetentionHeadersArg` - Headers of getRetentionPolicyAssignmentFileVersionUnderRetention method - ### Returns This function returns a value of type `FilesUnderRetention`. Returns a list of file versions under retention that are associated with the specified retention policy assignment. - - diff --git a/docs/search.md b/docs/search.md index b7524e09..be9aebcb 100644 --- a/docs/search.md +++ b/docs/search.md @@ -1,6 +1,5 @@ # SearchManager - - [Query files/folders by metadata](#query-files-folders-by-metadata) - [List metadata query indices](#list-metadata-query-indices) - [Search for content](#search-for-content) @@ -19,7 +18,7 @@ This operation is performed by calling function `createMetadataQueryExecuteRead` See the endpoint docs at [API Reference](https://developer.box.com/reference/post-metadata-queries-execute-read/). -*Currently we don't have an example for calling `createMetadataQueryExecuteRead` in integration tests* +_Currently we don't have an example for calling `createMetadataQueryExecuteRead` in integration tests_ ### Arguments @@ -28,14 +27,12 @@ See the endpoint docs at - headers `CreateMetadataQueryExecuteReadHeadersArg` - Headers of createMetadataQueryExecuteRead method - ### Returns This function returns a value of type `MetadataQueryResults`. Returns a list of files and folders that match this metadata query. - ## List metadata query indices Retrieves the metadata query indices for a given scope and template key. @@ -45,7 +42,7 @@ This operation is performed by calling function `getMetadataQueryIndices`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-metadata-query-indices/). -*Currently we don't have an example for calling `getMetadataQueryIndices` in integration tests* +_Currently we don't have an example for calling `getMetadataQueryIndices` in integration tests_ ### Arguments @@ -54,14 +51,12 @@ See the endpoint docs at - headers `GetMetadataQueryIndicesHeadersArg` - Headers of getMetadataQueryIndices method - ### Returns This function returns a value of type `MetadataQueryIndices`. Returns a collection of metadata query indices for scope and template key. - ## Search for content Searches for files, folders, web links, and shared files across the @@ -72,7 +67,7 @@ This operation is performed by calling function `getSearch`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-search/). -*Currently we don't have an example for calling `getSearch` in integration tests* +_Currently we don't have an example for calling `getSearch` in integration tests_ ### Arguments @@ -81,12 +76,9 @@ See the endpoint docs at - headers `GetSearchHeadersArg` - Headers of getSearch method - ### Returns This function returns a value of type `SearchResultsOrSearchResultsWithSharedLinks`. Returns a collection of search results. If there are no matching search results, the `entries` array will be empty. - - diff --git a/docs/sessionTermination.md b/docs/sessionTermination.md index 95a34342..3accd6d6 100644 --- a/docs/sessionTermination.md +++ b/docs/sessionTermination.md @@ -1,6 +1,5 @@ # SessionTerminationManager - - [Create jobs to terminate users session](#create-jobs-to-terminate-users-session) - [Create jobs to terminate user group session](#create-jobs-to-terminate-user-group-session) @@ -16,7 +15,7 @@ This operation is performed by calling function `createUserTerminateSession`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-users-terminate-sessions/). -*Currently we don't have an example for calling `createUserTerminateSession` in integration tests* +_Currently we don't have an example for calling `createUserTerminateSession` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `CreateUserTerminateSessionHeadersArg` - Headers of createUserTerminateSession method - ### Returns This function returns a value of type `SessionTerminationMessage`. Returns a message about the request status. - ## Create jobs to terminate user group session Validates the roles and permissions of the group, @@ -45,7 +42,7 @@ This operation is performed by calling function `createGroupTerminateSession`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-groups-terminate-sessions/). -*Currently we don't have an example for calling `createGroupTerminateSession` in integration tests* +_Currently we don't have an example for calling `createGroupTerminateSession` in integration tests_ ### Arguments @@ -54,11 +51,8 @@ See the endpoint docs at - headers `CreateGroupTerminateSessionHeadersArg` - Headers of createGroupTerminateSession method - ### Returns This function returns a value of type `SessionTerminationMessage`. Returns a message about the request status. - - diff --git a/docs/sharedLinksFiles.md b/docs/sharedLinksFiles.md index c563761b..92ad79e3 100644 --- a/docs/sharedLinksFiles.md +++ b/docs/sharedLinksFiles.md @@ -1,6 +1,5 @@ # SharedLinksFilesManager - - [Find file for shared link](#find-file-for-shared-link) - [Get shared link for file](#get-shared-link-for-file) - [Add shared link to file](#add-shared-link-to-file) @@ -25,7 +24,7 @@ This operation is performed by calling function `getSharedItems`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shared-items/). -*Currently we don't have an example for calling `getSharedItems` in integration tests* +_Currently we don't have an example for calling `getSharedItems` in integration tests_ ### Arguments @@ -34,7 +33,6 @@ See the endpoint docs at - headers `GetSharedItemsHeadersArg` - Headers of getSharedItems method - ### Returns This function returns a value of type `FileFull`. @@ -42,7 +40,6 @@ This function returns a value of type `FileFull`. Returns a full file resource if the shared link is valid and the user has access to it. - ## Get shared link for file Gets the information for a shared link on a file. @@ -52,18 +49,17 @@ This operation is performed by calling function `getFileGetSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-get-shared-link/). -*Currently we don't have an example for calling `getFileGetSharedLink` in integration tests* +_Currently we don't have an example for calling `getFileGetSharedLink` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - queryParams `GetFileGetSharedLinkQueryParamsArg` - Query parameters of getFileGetSharedLink method - headers `GetFileGetSharedLinkHeadersArg` - Headers of getFileGetSharedLink method - ### Returns This function returns a value of type `FileFull`. @@ -71,7 +67,6 @@ This function returns a value of type `FileFull`. Returns the base representation of a file with the additional shared link information. - ## Add shared link to file Adds a shared link to a file. @@ -81,12 +76,12 @@ This operation is performed by calling function `updateFileAddSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-add-shared-link/). -*Currently we don't have an example for calling `updateFileAddSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFileAddSharedLink` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `UpdateFileAddSharedLinkRequestBodyArg` - Request body of updateFileAddSharedLink method - queryParams `UpdateFileAddSharedLinkQueryParamsArg` @@ -94,7 +89,6 @@ See the endpoint docs at - headers `UpdateFileAddSharedLinkHeadersArg` - Headers of updateFileAddSharedLink method - ### Returns This function returns a value of type `FileFull`. @@ -102,7 +96,6 @@ This function returns a value of type `FileFull`. Returns the base representation of a file with a new shared link attached. - ## Update shared link on file Updates a shared link on a file. @@ -112,12 +105,12 @@ This operation is performed by calling function `updateFileUpdateSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-update-shared-link/). -*Currently we don't have an example for calling `updateFileUpdateSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFileUpdateSharedLink` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `UpdateFileUpdateSharedLinkRequestBodyArg` - Request body of updateFileUpdateSharedLink method - queryParams `UpdateFileUpdateSharedLinkQueryParamsArg` @@ -125,7 +118,6 @@ See the endpoint docs at - headers `UpdateFileUpdateSharedLinkHeadersArg` - Headers of updateFileUpdateSharedLink method - ### Returns This function returns a value of type `FileFull`. @@ -133,7 +125,6 @@ This function returns a value of type `FileFull`. Returns a basic representation of the file, with the updated shared link attached. - ## Remove shared link from file Removes a shared link from a file. @@ -143,12 +134,12 @@ This operation is performed by calling function `updateFileRemoveSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-remove-shared-link/). -*Currently we don't have an example for calling `updateFileRemoveSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFileRemoveSharedLink` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `UpdateFileRemoveSharedLinkRequestBodyArg` - Request body of updateFileRemoveSharedLink method - queryParams `UpdateFileRemoveSharedLinkQueryParamsArg` @@ -156,11 +147,8 @@ See the endpoint docs at - headers `UpdateFileRemoveSharedLinkHeadersArg` - Headers of updateFileRemoveSharedLink method - ### Returns This function returns a value of type `FileFull`. Returns a basic representation of a file, with the shared link removed. - - diff --git a/docs/sharedLinksFolders.md b/docs/sharedLinksFolders.md index aaf8231d..d3b24e55 100644 --- a/docs/sharedLinksFolders.md +++ b/docs/sharedLinksFolders.md @@ -1,6 +1,5 @@ # SharedLinksFoldersManager - - [Find folder for shared link](#find-folder-for-shared-link) - [Get shared link for folder](#get-shared-link-for-folder) - [Add shared link to folder](#add-shared-link-to-folder) @@ -22,7 +21,7 @@ This operation is performed by calling function `getSharedItemFolders`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shared-items-folders/). -*Currently we don't have an example for calling `getSharedItemFolders` in integration tests* +_Currently we don't have an example for calling `getSharedItemFolders` in integration tests_ ### Arguments @@ -31,7 +30,6 @@ See the endpoint docs at - headers `GetSharedItemFoldersHeadersArg` - Headers of getSharedItemFolders method - ### Returns This function returns a value of type `FolderFull`. @@ -39,7 +37,6 @@ This function returns a value of type `FolderFull`. Returns a full folder resource if the shared link is valid and the user has access to it. - ## Get shared link for folder Gets the information for a shared link on a folder. @@ -49,18 +46,17 @@ This operation is performed by calling function `getFolderGetSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-get-shared-link/). -*Currently we don't have an example for calling `getFolderGetSharedLink` in integration tests* +_Currently we don't have an example for calling `getFolderGetSharedLink` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - queryParams `GetFolderGetSharedLinkQueryParamsArg` - Query parameters of getFolderGetSharedLink method - headers `GetFolderGetSharedLinkHeadersArg` - Headers of getFolderGetSharedLink method - ### Returns This function returns a value of type `FolderFull`. @@ -68,7 +64,6 @@ This function returns a value of type `FolderFull`. Returns the base representation of a folder with the additional shared link information. - ## Add shared link to folder Adds a shared link to a folder. @@ -78,12 +73,12 @@ This operation is performed by calling function `updateFolderAddSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-add-shared-link/). -*Currently we don't have an example for calling `updateFolderAddSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFolderAddSharedLink` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `UpdateFolderAddSharedLinkRequestBodyArg` - Request body of updateFolderAddSharedLink method - queryParams `UpdateFolderAddSharedLinkQueryParamsArg` @@ -91,7 +86,6 @@ See the endpoint docs at - headers `UpdateFolderAddSharedLinkHeadersArg` - Headers of updateFolderAddSharedLink method - ### Returns This function returns a value of type `FolderFull`. @@ -99,7 +93,6 @@ This function returns a value of type `FolderFull`. Returns the base representation of a folder with a new shared link attached. - ## Update shared link on folder Updates a shared link on a folder. @@ -109,12 +102,12 @@ This operation is performed by calling function `updateFolderUpdateSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-update-shared-link/). -*Currently we don't have an example for calling `updateFolderUpdateSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFolderUpdateSharedLink` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `UpdateFolderUpdateSharedLinkRequestBodyArg` - Request body of updateFolderUpdateSharedLink method - queryParams `UpdateFolderUpdateSharedLinkQueryParamsArg` @@ -122,7 +115,6 @@ See the endpoint docs at - headers `UpdateFolderUpdateSharedLinkHeadersArg` - Headers of updateFolderUpdateSharedLink method - ### Returns This function returns a value of type `FolderFull`. @@ -130,7 +122,6 @@ This function returns a value of type `FolderFull`. Returns a basic representation of the folder, with the updated shared link attached. - ## Remove shared link from folder Removes a shared link from a folder. @@ -140,12 +131,12 @@ This operation is performed by calling function `updateFolderRemoveSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-folders-id-remove-shared-link/). -*Currently we don't have an example for calling `updateFolderRemoveSharedLink` in integration tests* +_Currently we don't have an example for calling `updateFolderRemoveSharedLink` in integration tests_ ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `UpdateFolderRemoveSharedLinkRequestBodyArg` - Request body of updateFolderRemoveSharedLink method - queryParams `UpdateFolderRemoveSharedLinkQueryParamsArg` @@ -153,11 +144,8 @@ See the endpoint docs at - headers `UpdateFolderRemoveSharedLinkHeadersArg` - Headers of updateFolderRemoveSharedLink method - ### Returns This function returns a value of type `FolderFull`. Returns a basic representation of a folder, with the shared link removed. - - diff --git a/docs/sharedLinksWebLinks.md b/docs/sharedLinksWebLinks.md index 7a0aacfd..73a21e76 100644 --- a/docs/sharedLinksWebLinks.md +++ b/docs/sharedLinksWebLinks.md @@ -1,6 +1,5 @@ # SharedLinksWebLinksManager - - [Find web link for shared link](#find-web-link-for-shared-link) - [Get shared link for web link](#get-shared-link-for-web-link) - [Add shared link to web link](#add-shared-link-to-web-link) @@ -22,7 +21,7 @@ This operation is performed by calling function `getSharedItemWebLinks`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shared-items-web-links/). -*Currently we don't have an example for calling `getSharedItemWebLinks` in integration tests* +_Currently we don't have an example for calling `getSharedItemWebLinks` in integration tests_ ### Arguments @@ -31,7 +30,6 @@ See the endpoint docs at - headers `GetSharedItemWebLinksHeadersArg` - Headers of getSharedItemWebLinks method - ### Returns This function returns a value of type `WebLink`. @@ -39,7 +37,6 @@ This function returns a value of type `WebLink`. Returns a full file resource if the shared link is valid and the user has access to it. - ## Get shared link for web link Gets the information for a shared link on a web link. @@ -49,7 +46,7 @@ This operation is performed by calling function `getWebLinkGetSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-web-links-id-get-shared-link/). -*Currently we don't have an example for calling `getWebLinkGetSharedLink` in integration tests* +_Currently we don't have an example for calling `getWebLinkGetSharedLink` in integration tests_ ### Arguments @@ -60,7 +57,6 @@ See the endpoint docs at - headers `GetWebLinkGetSharedLinkHeadersArg` - Headers of getWebLinkGetSharedLink method - ### Returns This function returns a value of type `WebLink`. @@ -68,7 +64,6 @@ This function returns a value of type `WebLink`. Returns the base representation of a web link with the additional shared link information. - ## Add shared link to web link Adds a shared link to a web link. @@ -78,7 +73,7 @@ This operation is performed by calling function `updateWebLinkAddSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-web-links-id-add-shared-link/). -*Currently we don't have an example for calling `updateWebLinkAddSharedLink` in integration tests* +_Currently we don't have an example for calling `updateWebLinkAddSharedLink` in integration tests_ ### Arguments @@ -91,7 +86,6 @@ See the endpoint docs at - headers `UpdateWebLinkAddSharedLinkHeadersArg` - Headers of updateWebLinkAddSharedLink method - ### Returns This function returns a value of type `WebLink`. @@ -99,7 +93,6 @@ This function returns a value of type `WebLink`. Returns the base representation of a web link with a new shared link attached. - ## Update shared link on web link Updates a shared link on a web link. @@ -109,7 +102,7 @@ This operation is performed by calling function `updateWebLinkUpdateSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-web-links-id-update-shared-link/). -*Currently we don't have an example for calling `updateWebLinkUpdateSharedLink` in integration tests* +_Currently we don't have an example for calling `updateWebLinkUpdateSharedLink` in integration tests_ ### Arguments @@ -122,7 +115,6 @@ See the endpoint docs at - headers `UpdateWebLinkUpdateSharedLinkHeadersArg` - Headers of updateWebLinkUpdateSharedLink method - ### Returns This function returns a value of type `WebLink`. @@ -130,7 +122,6 @@ This function returns a value of type `WebLink`. Returns a basic representation of the web link, with the updated shared link attached. - ## Remove shared link from web link Removes a shared link from a web link. @@ -140,7 +131,7 @@ This operation is performed by calling function `updateWebLinkRemoveSharedLink`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-web-links-id-remove-shared-link/). -*Currently we don't have an example for calling `updateWebLinkRemoveSharedLink` in integration tests* +_Currently we don't have an example for calling `updateWebLinkRemoveSharedLink` in integration tests_ ### Arguments @@ -153,12 +144,9 @@ See the endpoint docs at - headers `UpdateWebLinkRemoveSharedLinkHeadersArg` - Headers of updateWebLinkRemoveSharedLink method - ### Returns This function returns a value of type `WebLink`. Returns a basic representation of a web link, with the shared link removed. - - diff --git a/docs/shieldInformationBarrierReports.md b/docs/shieldInformationBarrierReports.md index 8c0179c2..95710324 100644 --- a/docs/shieldInformationBarrierReports.md +++ b/docs/shieldInformationBarrierReports.md @@ -1,6 +1,5 @@ # ShieldInformationBarrierReportsManager - - [List shield information barrier reports](#list-shield-information-barrier-reports) - [Create shield information barrier report](#create-shield-information-barrier-report) - [Get shield information barrier report by ID](#get-shield-information-barrier-report-by-id) @@ -14,7 +13,7 @@ This operation is performed by calling function `getShieldInformationBarrierRepo See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-reports/). -*Currently we don't have an example for calling `getShieldInformationBarrierReports` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierReports` in integration tests_ ### Arguments @@ -23,14 +22,12 @@ See the endpoint docs at - headers `GetShieldInformationBarrierReportsHeadersArg` - Headers of getShieldInformationBarrierReports method - ### Returns This function returns a value of type `undefined`. Returns a paginated list of shield information barrier report objects. - ## Create shield information barrier report Creates a shield information barrier report for a given barrier. @@ -40,7 +37,7 @@ This operation is performed by calling function `createShieldInformationBarrierR See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barrier-reports/). -*Currently we don't have an example for calling `createShieldInformationBarrierReport` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrierReport` in integration tests_ ### Arguments @@ -49,14 +46,12 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierReportHeadersArg` - Headers of createShieldInformationBarrierReport method - ### Returns This function returns a value of type `ShieldInformationBarrierReport`. Returns the shield information barrier report information object. - ## Get shield information barrier report by ID Retrieves a shield information barrier report by its ID. @@ -66,7 +61,7 @@ This operation is performed by calling function `getShieldInformationBarrierRepo See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-reports-id/). -*Currently we don't have an example for calling `getShieldInformationBarrierReportById` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierReportById` in integration tests_ ### Arguments @@ -75,11 +70,8 @@ See the endpoint docs at - headers `GetShieldInformationBarrierReportByIdHeadersArg` - Headers of getShieldInformationBarrierReportById method - ### Returns This function returns a value of type `ShieldInformationBarrierReport`. -Returns the shield information barrier report object. - - +Returns the shield information barrier report object. diff --git a/docs/shieldInformationBarrierSegmentMembers.md b/docs/shieldInformationBarrierSegmentMembers.md index 1d4ba6f2..3410105c 100644 --- a/docs/shieldInformationBarrierSegmentMembers.md +++ b/docs/shieldInformationBarrierSegmentMembers.md @@ -1,6 +1,5 @@ # ShieldInformationBarrierSegmentMembersManager - - [Get shield information barrier segment member by ID](#get-shield-information-barrier-segment-member-by-id) - [Delete shield information barrier segment member by ID](#delete-shield-information-barrier-segment-member-by-id) - [List shield information barrier segment members](#list-shield-information-barrier-segment-members) @@ -16,7 +15,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segment-members-id/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegmentMemberById` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegmentMemberById` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentMemberByIdHeadersArg` - Headers of getShieldInformationBarrierSegmentMemberById method - ### Returns This function returns a value of type `ShieldInformationBarrierSegmentMember`. Returns the shield information barrier segment member object. - ## Delete shield information barrier segment member by ID Deletes a shield information barrier @@ -43,7 +40,7 @@ This operation is performed by calling function `deleteShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-shield-information-barrier-segment-members-id/). -*Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentMemberById` in integration tests* +_Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentMemberById` in integration tests_ ### Arguments @@ -52,7 +49,6 @@ See the endpoint docs at - headers `DeleteShieldInformationBarrierSegmentMemberByIdHeadersArg` - Headers of deleteShieldInformationBarrierSegmentMemberById method - ### Returns This function returns a value of type `undefined`. @@ -60,7 +56,6 @@ This function returns a value of type `undefined`. Returns an empty response if the segment member was deleted successfully. - ## List shield information barrier segment members Lists shield information barrier segment members @@ -71,7 +66,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segment-members/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegmentMembers` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegmentMembers` in integration tests_ ### Arguments @@ -80,7 +75,6 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentMembersHeadersArg` - Headers of getShieldInformationBarrierSegmentMembers method - ### Returns This function returns a value of type `undefined`. @@ -88,7 +82,6 @@ This function returns a value of type `undefined`. Returns a paginated list of shield information barrier segment member objects. - ## Create shield information barrier segment member Creates a new shield information barrier segment member. @@ -98,7 +91,7 @@ This operation is performed by calling function `createShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barrier-segment-members/). -*Currently we don't have an example for calling `createShieldInformationBarrierSegmentMember` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrierSegmentMember` in integration tests_ ### Arguments @@ -107,11 +100,8 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierSegmentMemberHeadersArg` - Headers of createShieldInformationBarrierSegmentMember method - ### Returns This function returns a value of type `ShieldInformationBarrierSegmentMember`. Returns a new shield information barrier segment Member object. - - diff --git a/docs/shieldInformationBarrierSegmentRestrictions.md b/docs/shieldInformationBarrierSegmentRestrictions.md index af945918..7e7bb34f 100644 --- a/docs/shieldInformationBarrierSegmentRestrictions.md +++ b/docs/shieldInformationBarrierSegmentRestrictions.md @@ -1,6 +1,5 @@ # ShieldInformationBarrierSegmentRestrictionsManager - - [Get shield information barrier segment restriction by ID](#get-shield-information-barrier-segment-restriction-by-id) - [Delete shield information barrier segment restriction by ID](#delete-shield-information-barrier-segment-restriction-by-id) - [List shield information barrier segment restrictions](#list-shield-information-barrier-segment-restrictions) @@ -16,7 +15,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segment-restrictions-id/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegmentRestrictionById` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegmentRestrictionById` in integration tests_ ### Arguments @@ -25,7 +24,6 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentRestrictionByIdHeadersArg` - Headers of getShieldInformationBarrierSegmentRestrictionById method - ### Returns This function returns a value of type `ShieldInformationBarrierSegmentRestriction`. @@ -33,7 +31,6 @@ This function returns a value of type `ShieldInformationBarrierSegmentRestrictio Returns the shield information barrier segment restriction object. - ## Delete shield information barrier segment restriction by ID Delete shield information barrier segment restriction @@ -44,7 +41,7 @@ This operation is performed by calling function `deleteShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-shield-information-barrier-segment-restrictions-id/). -*Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentRestrictionById` in integration tests* +_Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentRestrictionById` in integration tests_ ### Arguments @@ -53,14 +50,12 @@ See the endpoint docs at - headers `DeleteShieldInformationBarrierSegmentRestrictionByIdHeadersArg` - Headers of deleteShieldInformationBarrierSegmentRestrictionById method - ### Returns This function returns a value of type `undefined`. Empty body in response - ## List shield information barrier segment restrictions Lists shield information barrier segment restrictions @@ -71,7 +66,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segment-restrictions/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegmentRestrictions` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegmentRestrictions` in integration tests_ ### Arguments @@ -80,7 +75,6 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentRestrictionsHeadersArg` - Headers of getShieldInformationBarrierSegmentRestrictions method - ### Returns This function returns a value of type `undefined`. @@ -88,7 +82,6 @@ This function returns a value of type `undefined`. Returns a paginated list of shield information barrier segment restriction objects. - ## Create shield information barrier segment restriction Creates a shield information barrier @@ -99,7 +92,7 @@ This operation is performed by calling function `createShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barrier-segment-restrictions/). -*Currently we don't have an example for calling `createShieldInformationBarrierSegmentRestriction` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrierSegmentRestriction` in integration tests_ ### Arguments @@ -108,12 +101,9 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierSegmentRestrictionHeadersArg` - Headers of createShieldInformationBarrierSegmentRestriction method - ### Returns This function returns a value of type `ShieldInformationBarrierSegmentRestriction`. Returns the newly created Shield Information Barrier Segment Restriction object. - - diff --git a/docs/shieldInformationBarrierSegments.md b/docs/shieldInformationBarrierSegments.md index cdc7effd..2c9869ab 100644 --- a/docs/shieldInformationBarrierSegments.md +++ b/docs/shieldInformationBarrierSegments.md @@ -1,6 +1,5 @@ # ShieldInformationBarrierSegmentsManager - - [Get shield information barrier segment with specified ID](#get-shield-information-barrier-segment-with-specified-id) - [Update shield information barrier segment with specified ID](#update-shield-information-barrier-segment-with-specified-id) - [Delete shield information barrier segment](#delete-shield-information-barrier-segment) @@ -16,7 +15,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segments-id/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegmentById` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegmentById` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentByIdHeadersArg` - Headers of getShieldInformationBarrierSegmentById method - ### Returns This function returns a value of type `ShieldInformationBarrierSegment`. Returns the shield information barrier segment object. - ## Update shield information barrier segment with specified ID Updates the shield information barrier segment based on provided ID.. @@ -42,7 +39,7 @@ This operation is performed by calling function `updateShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/put-shield-information-barrier-segments-id/). -*Currently we don't have an example for calling `updateShieldInformationBarrierSegmentById` in integration tests* +_Currently we don't have an example for calling `updateShieldInformationBarrierSegmentById` in integration tests_ ### Arguments @@ -53,14 +50,12 @@ See the endpoint docs at - headers `UpdateShieldInformationBarrierSegmentByIdHeadersArg` - Headers of updateShieldInformationBarrierSegmentById method - ### Returns This function returns a value of type `ShieldInformationBarrierSegment`. Returns the updated shield information barrier segment object. - ## Delete shield information barrier segment Deletes the shield information barrier segment @@ -71,7 +66,7 @@ This operation is performed by calling function `deleteShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-shield-information-barrier-segments-id/). -*Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentById` in integration tests* +_Currently we don't have an example for calling `deleteShieldInformationBarrierSegmentById` in integration tests_ ### Arguments @@ -80,14 +75,12 @@ See the endpoint docs at - headers `DeleteShieldInformationBarrierSegmentByIdHeadersArg` - Headers of deleteShieldInformationBarrierSegmentById method - ### Returns This function returns a value of type `undefined`. Empty body in response - ## List shield information barrier segments Retrieves a list of shield information barrier segment objects @@ -98,7 +91,7 @@ This operation is performed by calling function `getShieldInformationBarrierSegm See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barrier-segments/). -*Currently we don't have an example for calling `getShieldInformationBarrierSegments` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierSegments` in integration tests_ ### Arguments @@ -107,14 +100,12 @@ See the endpoint docs at - headers `GetShieldInformationBarrierSegmentsHeadersArg` - Headers of getShieldInformationBarrierSegments method - ### Returns This function returns a value of type `undefined`. Returns a paginated list of shield information barrier segment objects. - ## Create shield information barrier segment Creates a shield information barrier segment. @@ -124,7 +115,7 @@ This operation is performed by calling function `createShieldInformationBarrierS See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barrier-segments/). -*Currently we don't have an example for calling `createShieldInformationBarrierSegment` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrierSegment` in integration tests_ ### Arguments @@ -133,11 +124,8 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierSegmentHeadersArg` - Headers of createShieldInformationBarrierSegment method - ### Returns This function returns a value of type `ShieldInformationBarrierSegment`. Returns a new shield information barrier segment object. - - diff --git a/docs/shieldInformationBarriers.md b/docs/shieldInformationBarriers.md index f96afcb6..b5642b26 100644 --- a/docs/shieldInformationBarriers.md +++ b/docs/shieldInformationBarriers.md @@ -1,6 +1,5 @@ # ShieldInformationBarriersManager - - [Get shield information barrier with specified ID](#get-shield-information-barrier-with-specified-id) - [Add changed status of shield information barrier with specified ID](#add-changed-status-of-shield-information-barrier-with-specified-id) - [List shield information barriers](#list-shield-information-barriers) @@ -15,7 +14,7 @@ This operation is performed by calling function `getShieldInformationBarrierById See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barriers-id/). -*Currently we don't have an example for calling `getShieldInformationBarrierById` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarrierById` in integration tests_ ### Arguments @@ -24,14 +23,12 @@ See the endpoint docs at - headers `GetShieldInformationBarrierByIdHeadersArg` - Headers of getShieldInformationBarrierById method - ### Returns This function returns a value of type `ShieldInformationBarrier`. Returns the shield information barrier object. - ## Add changed status of shield information barrier with specified ID Change status of shield information barrier with the specified ID. @@ -41,7 +38,7 @@ This operation is performed by calling function `createShieldInformationBarrierC See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barriers-change-status/). -*Currently we don't have an example for calling `createShieldInformationBarrierChangeStatus` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrierChangeStatus` in integration tests_ ### Arguments @@ -50,14 +47,12 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierChangeStatusHeadersArg` - Headers of createShieldInformationBarrierChangeStatus method - ### Returns This function returns a value of type `ShieldInformationBarrier`. Returns the updated shield information barrier object. - ## List shield information barriers Retrieves a list of shield information barrier objects @@ -68,7 +63,7 @@ This operation is performed by calling function `getShieldInformationBarriers`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-shield-information-barriers/). -*Currently we don't have an example for calling `getShieldInformationBarriers` in integration tests* +_Currently we don't have an example for calling `getShieldInformationBarriers` in integration tests_ ### Arguments @@ -77,7 +72,6 @@ See the endpoint docs at - headers `GetShieldInformationBarriersHeadersArg` - Headers of getShieldInformationBarriers method - ### Returns This function returns a value of type `undefined`. @@ -86,7 +80,6 @@ Returns a paginated list of shield information barrier objects, empty list if currently no barrier. - ## Create shield information barrier Creates a shield information barrier to @@ -98,7 +91,7 @@ This operation is performed by calling function `createShieldInformationBarrier` See the endpoint docs at [API Reference](https://developer.box.com/reference/post-shield-information-barriers/). -*Currently we don't have an example for calling `createShieldInformationBarrier` in integration tests* +_Currently we don't have an example for calling `createShieldInformationBarrier` in integration tests_ ### Arguments @@ -107,11 +100,8 @@ See the endpoint docs at - headers `CreateShieldInformationBarrierHeadersArg` - Headers of createShieldInformationBarrier method - ### Returns This function returns a value of type `ShieldInformationBarrier`. Returns a new shield information barrier object. - - diff --git a/docs/signTemplates.md b/docs/signTemplates.md index 0d59e163..17b7721a 100644 --- a/docs/signTemplates.md +++ b/docs/signTemplates.md @@ -1,6 +1,5 @@ # SignTemplatesManager - - [List Box Sign templates](#list-box-sign-templates) - [Get Box Sign template by ID](#get-box-sign-template-by-id) @@ -13,7 +12,7 @@ This operation is performed by calling function `getSignTemplates`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-sign-templates/). -*Currently we don't have an example for calling `getSignTemplates` in integration tests* +_Currently we don't have an example for calling `getSignTemplates` in integration tests_ ### Arguments @@ -22,14 +21,12 @@ See the endpoint docs at - headers `GetSignTemplatesHeadersArg` - Headers of getSignTemplates method - ### Returns This function returns a value of type `SignTemplates`. Returns a collection of templates. - ## Get Box Sign template by ID Fetches details of a specific Box Sign template. @@ -39,7 +36,7 @@ This operation is performed by calling function `getSignTemplateById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-sign-templates-id/). -*Currently we don't have an example for calling `getSignTemplateById` in integration tests* +_Currently we don't have an example for calling `getSignTemplateById` in integration tests_ ### Arguments @@ -48,11 +45,8 @@ See the endpoint docs at - headers `GetSignTemplateByIdHeadersArg` - Headers of getSignTemplateById method - ### Returns This function returns a value of type `SignTemplate`. Returns details of a template. - - diff --git a/docs/skills.md b/docs/skills.md index a347e128..fb62d5b2 100644 --- a/docs/skills.md +++ b/docs/skills.md @@ -1,6 +1,5 @@ # SkillsManager - - [List Box Skill cards on file](#list-box-skill-cards-on-file) - [Create Box Skill cards on file](#create-box-skill-cards-on-file) - [Update Box Skill cards on file](#update-box-skill-cards-on-file) @@ -16,16 +15,15 @@ This operation is performed by calling function `getFileMetadataGlobalBoxSkillsC See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-metadata-global-box-skills-cards/). -*Currently we don't have an example for calling `getFileMetadataGlobalBoxSkillsCards` in integration tests* +_Currently we don't have an example for calling `getFileMetadataGlobalBoxSkillsCards` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `GetFileMetadataGlobalBoxSkillsCardsHeadersArg` - Headers of getFileMetadataGlobalBoxSkillsCards method - ### Returns This function returns a value of type `SkillCardsMetadata`. @@ -35,7 +33,6 @@ Returns all the metadata associated with a file. This API does not support pagination and will therefore always return all of the metadata associated to the file. - ## Create Box Skill cards on file Applies one or more Box Skills metadata cards to a file. @@ -45,18 +42,17 @@ This operation is performed by calling function `createFileMetadataGlobalBoxSkil See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id-metadata-global-box-skills-cards/). -*Currently we don't have an example for calling `createFileMetadataGlobalBoxSkillsCard` in integration tests* +_Currently we don't have an example for calling `createFileMetadataGlobalBoxSkillsCard` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `CreateFileMetadataGlobalBoxSkillsCardRequestBodyArg` - Request body of createFileMetadataGlobalBoxSkillsCard method - headers `CreateFileMetadataGlobalBoxSkillsCardHeadersArg` - Headers of createFileMetadataGlobalBoxSkillsCard method - ### Returns This function returns a value of type `SkillCardsMetadata`. @@ -64,7 +60,6 @@ This function returns a value of type `SkillCardsMetadata`. Returns the instance of the template that was applied to the file, including the data that was applied to the template. - ## Update Box Skill cards on file Updates one or more Box Skills metadata cards to a file. @@ -74,18 +69,17 @@ This operation is performed by calling function `updateFileMetadataGlobalBoxSkil See the endpoint docs at [API Reference](https://developer.box.com/reference/put-files-id-metadata-global-box-skills-cards/). -*Currently we don't have an example for calling `updateFileMetadataGlobalBoxSkillsCard` in integration tests* +_Currently we don't have an example for calling `updateFileMetadataGlobalBoxSkillsCard` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `readonly UpdateFileMetadataGlobalBoxSkillsCardRequestBodyArg[]` - Request body of updateFileMetadataGlobalBoxSkillsCard method - headers `UpdateFileMetadataGlobalBoxSkillsCardHeadersArg` - Headers of updateFileMetadataGlobalBoxSkillsCard method - ### Returns This function returns a value of type `SkillCardsMetadata`. @@ -93,7 +87,6 @@ This function returns a value of type `SkillCardsMetadata`. Returns the updated metadata template, with the custom template data included. - ## Remove Box Skill cards from file Removes any Box Skills cards metadata from a file. @@ -103,16 +96,15 @@ This operation is performed by calling function `deleteFileMetadataGlobalBoxSkil See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-metadata-global-box-skills-cards/). -*Currently we don't have an example for calling `deleteFileMetadataGlobalBoxSkillsCard` in integration tests* +_Currently we don't have an example for calling `deleteFileMetadataGlobalBoxSkillsCard` in integration tests_ ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `DeleteFileMetadataGlobalBoxSkillsCardHeadersArg` - Headers of deleteFileMetadataGlobalBoxSkillsCard method - ### Returns This function returns a value of type `undefined`. @@ -120,7 +112,6 @@ This function returns a value of type `undefined`. Returns an empty response when the cards are successfully deleted. - ## Update all Box Skill cards on file An alternative method that can be used to overwrite and update all Box Skill @@ -131,7 +122,7 @@ This operation is performed by calling function `updateSkillInvocationById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-skill-invocations-id/). -*Currently we don't have an example for calling `updateSkillInvocationById` in integration tests* +_Currently we don't have an example for calling `updateSkillInvocationById` in integration tests_ ### Arguments @@ -142,11 +133,8 @@ See the endpoint docs at - headers `UpdateSkillInvocationByIdHeadersArg` - Headers of updateSkillInvocationById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the card has been successfully updated. - - diff --git a/docs/storagePolicies.md b/docs/storagePolicies.md index a3211cff..4cfd3a42 100644 --- a/docs/storagePolicies.md +++ b/docs/storagePolicies.md @@ -1,6 +1,5 @@ # StoragePoliciesManager - - [List storage policies](#list-storage-policies) - [Get storage policy](#get-storage-policy) @@ -15,7 +14,7 @@ This operation is performed by calling function `getStoragePolicies`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-storage-policies/). -*Currently we don't have an example for calling `getStoragePolicies` in integration tests* +_Currently we don't have an example for calling `getStoragePolicies` in integration tests_ ### Arguments @@ -24,14 +23,12 @@ See the endpoint docs at - headers `GetStoragePoliciesHeadersArg` - Headers of getStoragePolicies method - ### Returns This function returns a value of type `StoragePolicies`. Returns a collection of storage policies. - ## Get storage policy Fetches a specific storage policy. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. @@ -41,7 +38,7 @@ This operation is performed by calling function `getStoragePolicyById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-storage-policies-id/). -*Currently we don't have an example for calling `getStoragePolicyById` in integration tests* +_Currently we don't have an example for calling `getStoragePolicyById` in integration tests_ ### Arguments @@ -50,11 +47,8 @@ See the endpoint docs at - headers `GetStoragePolicyByIdHeadersArg` - Headers of getStoragePolicyById method - ### Returns This function returns a value of type `StoragePolicy`. Returns a storage policy object. - - diff --git a/docs/storagePolicyAssignments.md b/docs/storagePolicyAssignments.md index 2bb8dc3a..c6f398ed 100644 --- a/docs/storagePolicyAssignments.md +++ b/docs/storagePolicyAssignments.md @@ -1,6 +1,5 @@ # StoragePolicyAssignmentsManager - - [List storage policy assignments](#list-storage-policy-assignments) - [Assign storage policy](#assign-storage-policy) - [Get storage policy assignment](#get-storage-policy-assignment) @@ -18,7 +17,7 @@ This operation is performed by calling function `getStoragePolicyAssignments`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-storage-policy-assignments/). -*Currently we don't have an example for calling `getStoragePolicyAssignments` in integration tests* +_Currently we don't have an example for calling `getStoragePolicyAssignments` in integration tests_ ### Arguments @@ -27,7 +26,6 @@ See the endpoint docs at - headers `GetStoragePolicyAssignmentsHeadersArg` - Headers of getStoragePolicyAssignments method - ### Returns This function returns a value of type `StoragePolicyAssignments`. @@ -35,7 +33,6 @@ This function returns a value of type `StoragePolicyAssignments`. Returns a collection of storage policies for the enterprise or user. - ## Assign storage policy Creates a storage policy assignment for an enterprise or user. @@ -47,7 +44,7 @@ This operation is performed by calling function `createStoragePolicyAssignment`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-storage-policy-assignments/). -*Currently we don't have an example for calling `createStoragePolicyAssignment` in integration tests* +_Currently we don't have an example for calling `createStoragePolicyAssignment` in integration tests_ ### Arguments @@ -56,14 +53,12 @@ See the endpoint docs at - headers `CreateStoragePolicyAssignmentHeadersArg` - Headers of createStoragePolicyAssignment method - ### Returns This function returns a value of type `StoragePolicyAssignment`. Returns the new storage policy assignment created. - ## Get storage policy assignment Fetches a specific storage policy assignment. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. @@ -73,7 +68,7 @@ This operation is performed by calling function `getStoragePolicyAssignmentById` See the endpoint docs at [API Reference](https://developer.box.com/reference/get-storage-policy-assignments-id/). -*Currently we don't have an example for calling `getStoragePolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `getStoragePolicyAssignmentById` in integration tests_ ### Arguments @@ -82,14 +77,12 @@ See the endpoint docs at - headers `GetStoragePolicyAssignmentByIdHeadersArg` - Headers of getStoragePolicyAssignmentById method - ### Returns This function returns a value of type `StoragePolicyAssignment`. Returns a storage policy assignment object. - ## Update storage policy assignment Updates a specific storage policy assignment. Only a Primary Admin can access this endpoint. The user needs to generate a token for an account to authenticate this request. @@ -99,7 +92,7 @@ This operation is performed by calling function `updateStoragePolicyAssignmentBy See the endpoint docs at [API Reference](https://developer.box.com/reference/put-storage-policy-assignments-id/). -*Currently we don't have an example for calling `updateStoragePolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `updateStoragePolicyAssignmentById` in integration tests_ ### Arguments @@ -110,14 +103,12 @@ See the endpoint docs at - headers `UpdateStoragePolicyAssignmentByIdHeadersArg` - Headers of updateStoragePolicyAssignmentById method - ### Returns This function returns a value of type `StoragePolicyAssignment`. Returns an updated storage policy assignment object. - ## Unassign storage policy Delete a storage policy assignment. @@ -137,7 +128,7 @@ This operation is performed by calling function `deleteStoragePolicyAssignmentBy See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-storage-policy-assignments-id/). -*Currently we don't have an example for calling `deleteStoragePolicyAssignmentById` in integration tests* +_Currently we don't have an example for calling `deleteStoragePolicyAssignmentById` in integration tests_ ### Arguments @@ -146,12 +137,9 @@ See the endpoint docs at - headers `DeleteStoragePolicyAssignmentByIdHeadersArg` - Headers of deleteStoragePolicyAssignmentById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the storage policy assignment is successfully deleted. - - diff --git a/docs/taskAssignments.md b/docs/taskAssignments.md index fdb40e82..bce31627 100644 --- a/docs/taskAssignments.md +++ b/docs/taskAssignments.md @@ -1,6 +1,5 @@ # TaskAssignmentsManager - - [List task assignments](#list-task-assignments) - [Assign task](#assign-task) - [Get task assignment](#get-task-assignment) @@ -16,7 +15,7 @@ This operation is performed by calling function `getTaskAssignments`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-tasks-id-assignments/). -*Currently we don't have an example for calling `getTaskAssignments` in integration tests* +_Currently we don't have an example for calling `getTaskAssignments` in integration tests_ ### Arguments @@ -25,7 +24,6 @@ See the endpoint docs at - headers `GetTaskAssignmentsHeadersArg` - Headers of getTaskAssignments method - ### Returns This function returns a value of type `TaskAssignments`. @@ -33,7 +31,6 @@ This function returns a value of type `TaskAssignments`. Returns a collection of task assignment defining what task on a file has been assigned to which users and by who. - ## Assign task Assigns a task to a user. @@ -46,7 +43,7 @@ This operation is performed by calling function `createTaskAssignment`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-task-assignments/). -*Currently we don't have an example for calling `createTaskAssignment` in integration tests* +_Currently we don't have an example for calling `createTaskAssignment` in integration tests_ ### Arguments @@ -55,14 +52,12 @@ See the endpoint docs at - headers `CreateTaskAssignmentHeadersArg` - Headers of createTaskAssignment method - ### Returns This function returns a value of type `TaskAssignment`. Returns a new task assignment object. - ## Get task assignment Retrieves information about a task assignment. @@ -72,7 +67,7 @@ This operation is performed by calling function `getTaskAssignmentById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-task-assignments-id/). -*Currently we don't have an example for calling `getTaskAssignmentById` in integration tests* +_Currently we don't have an example for calling `getTaskAssignmentById` in integration tests_ ### Arguments @@ -81,7 +76,6 @@ See the endpoint docs at - headers `GetTaskAssignmentByIdHeadersArg` - Headers of getTaskAssignmentById method - ### Returns This function returns a value of type `TaskAssignment`. @@ -89,7 +83,6 @@ This function returns a value of type `TaskAssignment`. Returns a task assignment, specifying who the task has been assigned to and by whom. - ## Update task assignment Updates a task assignment. This endpoint can be @@ -100,7 +93,7 @@ This operation is performed by calling function `updateTaskAssignmentById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-task-assignments-id/). -*Currently we don't have an example for calling `updateTaskAssignmentById` in integration tests* +_Currently we don't have an example for calling `updateTaskAssignmentById` in integration tests_ ### Arguments @@ -111,14 +104,12 @@ See the endpoint docs at - headers `UpdateTaskAssignmentByIdHeadersArg` - Headers of updateTaskAssignmentById method - ### Returns This function returns a value of type `TaskAssignment`. Returns the updated task assignment object. - ## Unassign task Deletes a specific task assignment. @@ -128,7 +119,7 @@ This operation is performed by calling function `deleteTaskAssignmentById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-task-assignments-id/). -*Currently we don't have an example for calling `deleteTaskAssignmentById` in integration tests* +_Currently we don't have an example for calling `deleteTaskAssignmentById` in integration tests_ ### Arguments @@ -137,12 +128,9 @@ See the endpoint docs at - headers `DeleteTaskAssignmentByIdHeadersArg` - Headers of deleteTaskAssignmentById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the task assignment was successfully deleted. - - diff --git a/docs/tasks.md b/docs/tasks.md index 4076ebe6..6cf6007b 100644 --- a/docs/tasks.md +++ b/docs/tasks.md @@ -1,6 +1,5 @@ # TasksManager - - [List tasks on file](#list-tasks-on-file) - [Create task](#create-task) - [Get task](#get-task) @@ -18,18 +17,18 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-tasks/). + ```ts -await client.tasks.getFileTasks(file.id) +await client.tasks.getFileTasks(file.id); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `GetFileTasksHeadersArg` - Headers of getFileTasks method - ### Returns This function returns a value of type `Tasks`. @@ -39,7 +38,6 @@ Returns a list of tasks on a file. If there are no tasks on this file an empty collection is returned instead. - ## Create task Creates a single task on a file. This task is not assigned to any user and @@ -51,8 +49,19 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-tasks/). + ```ts -await client.tasks.createTask({ item: { type: "file" as CreateTaskRequestBodyArgItemFieldTypeField, id: file.id } satisfies CreateTaskRequestBodyArgItemField, message: "test message", dueAt: "2035-01-01T00:00:00Z", action: "review" as CreateTaskRequestBodyArgActionField, completionRule: "all_assignees" as CreateTaskRequestBodyArgCompletionRuleField } satisfies CreateTaskRequestBodyArg) +await client.tasks.createTask({ + item: { + type: 'file' as CreateTaskRequestBodyArgItemFieldTypeField, + id: file.id, + } satisfies CreateTaskRequestBodyArgItemField, + message: 'test message', + dueAt: '2035-01-01T00:00:00Z', + action: 'review' as CreateTaskRequestBodyArgActionField, + completionRule: + 'all_assignees' as CreateTaskRequestBodyArgCompletionRuleField, +} satisfies CreateTaskRequestBodyArg); ``` ### Arguments @@ -62,14 +71,12 @@ await client.tasks.createTask({ item: { type: "file" as CreateTaskRequestBodyArg - headers `CreateTaskHeadersArg` - Headers of createTask method - ### Returns This function returns a value of type `Task`. Returns the newly created task. - ## Get task Retrieves information about a specific task. @@ -80,8 +87,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-tasks-id/). + ```ts -await client.tasks.getTaskById(task.id) +await client.tasks.getTaskById(task.id); ``` ### Arguments @@ -91,14 +99,12 @@ await client.tasks.getTaskById(task.id) - headers `GetTaskByIdHeadersArg` - Headers of getTaskById method - ### Returns This function returns a value of type `Task`. Returns a task object. - ## Update task Updates a task. This can be used to update a task's configuration, or to @@ -110,8 +116,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-tasks-id/). + ```ts -await client.tasks.updateTaskById(task.id, { message: "updated message" } satisfies UpdateTaskByIdRequestBodyArg) +await client.tasks.updateTaskById(task.id, { + message: 'updated message', +} satisfies UpdateTaskByIdRequestBodyArg); ``` ### Arguments @@ -123,14 +132,12 @@ await client.tasks.updateTaskById(task.id, { message: "updated message" } satisf - headers `UpdateTaskByIdHeadersArg` - Headers of updateTaskById method - ### Returns This function returns a value of type `Task`. Returns the updated task object - ## Remove task Removes a task from a file. @@ -141,8 +148,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-tasks-id/). + ```ts -await client.tasks.deleteTaskById(task.id) +await client.tasks.deleteTaskById(task.id); ``` ### Arguments @@ -152,11 +160,8 @@ await client.tasks.deleteTaskById(task.id) - headers `DeleteTaskByIdHeadersArg` - Headers of deleteTaskById method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the task was successfully deleted. - - diff --git a/docs/termsOfServiceUserStatuses.md b/docs/termsOfServiceUserStatuses.md index b40ab996..e0329768 100644 --- a/docs/termsOfServiceUserStatuses.md +++ b/docs/termsOfServiceUserStatuses.md @@ -1,6 +1,5 @@ # TermsOfServiceUserStatusesManager - - [List terms of service user statuses](#list-terms-of-service-user-statuses) - [Create terms of service status for new user](#create-terms-of-service-status-for-new-user) - [Update terms of service status for existing user](#update-terms-of-service-status-for-existing-user) @@ -16,7 +15,7 @@ This operation is performed by calling function `getTermOfServiceUserStatuses`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-terms-of-service-user-statuses/). -*Currently we don't have an example for calling `getTermOfServiceUserStatuses` in integration tests* +_Currently we don't have an example for calling `getTermOfServiceUserStatuses` in integration tests_ ### Arguments @@ -25,14 +24,12 @@ See the endpoint docs at - headers `GetTermOfServiceUserStatusesHeadersArg` - Headers of getTermOfServiceUserStatuses method - ### Returns This function returns a value of type `TermsOfServiceUserStatuses`. Returns a list of terms of service statuses. - ## Create terms of service status for new user Sets the status for a terms of service for a user. @@ -42,7 +39,7 @@ This operation is performed by calling function `createTermOfServiceUserStatus`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-terms-of-service-user-statuses/). -*Currently we don't have an example for calling `createTermOfServiceUserStatus` in integration tests* +_Currently we don't have an example for calling `createTermOfServiceUserStatus` in integration tests_ ### Arguments @@ -51,14 +48,12 @@ See the endpoint docs at - headers `CreateTermOfServiceUserStatusHeadersArg` - Headers of createTermOfServiceUserStatus method - ### Returns This function returns a value of type `TermsOfServiceUserStatus`. Returns a terms of service status object. - ## Update terms of service status for existing user Updates the status for a terms of service for a user. @@ -68,7 +63,7 @@ This operation is performed by calling function `updateTermOfServiceUserStatusBy See the endpoint docs at [API Reference](https://developer.box.com/reference/put-terms-of-service-user-statuses-id/). -*Currently we don't have an example for calling `updateTermOfServiceUserStatusById` in integration tests* +_Currently we don't have an example for calling `updateTermOfServiceUserStatusById` in integration tests_ ### Arguments @@ -79,11 +74,8 @@ See the endpoint docs at - headers `UpdateTermOfServiceUserStatusByIdHeadersArg` - Headers of updateTermOfServiceUserStatusById method - ### Returns This function returns a value of type `TermsOfServiceUserStatus`. Returns the updated terms of service status object. - - diff --git a/docs/termsOfServices.md b/docs/termsOfServices.md index 3b3d7fc0..9e8f49d3 100644 --- a/docs/termsOfServices.md +++ b/docs/termsOfServices.md @@ -1,6 +1,5 @@ # TermsOfServicesManager - - [List terms of services](#list-terms-of-services) - [Create terms of service](#create-terms-of-service) - [Get terms of service](#get-terms-of-service) @@ -16,7 +15,7 @@ This operation is performed by calling function `getTermOfServices`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-terms-of-services/). -*Currently we don't have an example for calling `getTermOfServices` in integration tests* +_Currently we don't have an example for calling `getTermOfServices` in integration tests_ ### Arguments @@ -25,7 +24,6 @@ See the endpoint docs at - headers `GetTermOfServicesHeadersArg` - Headers of getTermOfServices method - ### Returns This function returns a value of type `TermsOfServices`. @@ -33,7 +31,6 @@ This function returns a value of type `TermsOfServices`. Returns a collection of terms of service text and settings for the enterprise. - ## Create terms of service Creates a terms of service for a given enterprise @@ -44,7 +41,7 @@ This operation is performed by calling function `createTermOfService`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-terms-of-services/). -*Currently we don't have an example for calling `createTermOfService` in integration tests* +_Currently we don't have an example for calling `createTermOfService` in integration tests_ ### Arguments @@ -53,14 +50,12 @@ See the endpoint docs at - headers `CreateTermOfServiceHeadersArg` - Headers of createTermOfService method - ### Returns This function returns a value of type `Task`. Returns a new task object - ## Get terms of service Fetches a specific terms of service. @@ -70,7 +65,7 @@ This operation is performed by calling function `getTermOfServiceById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-terms-of-services-id/). -*Currently we don't have an example for calling `getTermOfServiceById` in integration tests* +_Currently we don't have an example for calling `getTermOfServiceById` in integration tests_ ### Arguments @@ -79,14 +74,12 @@ See the endpoint docs at - headers `GetTermOfServiceByIdHeadersArg` - Headers of getTermOfServiceById method - ### Returns This function returns a value of type `TermsOfService`. Returns a terms of service object. - ## Update terms of service Updates a specific terms of service. @@ -96,7 +89,7 @@ This operation is performed by calling function `updateTermOfServiceById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-terms-of-services-id/). -*Currently we don't have an example for calling `updateTermOfServiceById` in integration tests* +_Currently we don't have an example for calling `updateTermOfServiceById` in integration tests_ ### Arguments @@ -107,11 +100,8 @@ See the endpoint docs at - headers `UpdateTermOfServiceByIdHeadersArg` - Headers of updateTermOfServiceById method - ### Returns This function returns a value of type `TermsOfService`. Returns an updated terms of service object. - - diff --git a/docs/transfer.md b/docs/transfer.md index b74258b2..8af021b7 100644 --- a/docs/transfer.md +++ b/docs/transfer.md @@ -1,6 +1,5 @@ # TransferManager - - [Transfer owned folders](#transfer-owned-folders) ## Transfer owned folders @@ -44,7 +43,7 @@ This operation is performed by calling function `transferOwnedFolder`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-users-id-folders-0/). -*Currently we don't have an example for calling `transferOwnedFolder` in integration tests* +_Currently we don't have an example for calling `transferOwnedFolder` in integration tests_ ### Arguments @@ -57,12 +56,9 @@ See the endpoint docs at - headers `TransferOwnedFolderHeadersArg` - Headers of transferOwnedFolder method - ### Returns This function returns a value of type `FolderFull`. Returns the information for the newly created destination folder. - - diff --git a/docs/trashedFiles.md b/docs/trashedFiles.md index ca6a93ec..344fa76f 100644 --- a/docs/trashedFiles.md +++ b/docs/trashedFiles.md @@ -1,6 +1,5 @@ # TrashedFilesManager - - [Restore file](#restore-file) - [Get trashed file](#get-trashed-file) - [Permanently remove file](#permanently-remove-file) @@ -18,14 +17,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-files-id/). + ```ts -await client.trashedFiles.restoreFileFromTrash(file.id) +await client.trashedFiles.restoreFileFromTrash(file.id); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - requestBody `RestoreFileFromTrashRequestBodyArg` - Request body of restoreFileFromTrash method - queryParams `RestoreFileFromTrashQueryParamsArg` @@ -33,14 +33,12 @@ await client.trashedFiles.restoreFileFromTrash(file.id) - headers `RestoreFileFromTrashHeadersArg` - Headers of restoreFileFromTrash method - ### Returns This function returns a value of type `TrashFileRestored`. Returns a file object when the file has been restored. - ## Get trashed file Retrieves a file that has been moved to the trash. @@ -61,20 +59,20 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-files-id-trash/). + ```ts -await client.trashedFiles.getFileTrash(file.id) +await client.trashedFiles.getFileTrash(file.id); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - queryParams `GetFileTrashQueryParamsArg` - Query parameters of getFileTrash method - headers `GetFileTrashHeadersArg` - Headers of getFileTrash method - ### Returns This function returns a value of type `TrashFile`. @@ -83,7 +81,6 @@ Returns the file that was trashed, including information about when the it was moved to the trash. - ## Permanently remove file Permanently deletes a file that is in the trash. @@ -95,23 +92,21 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-files-id-trash/). + ```ts -await client.trashedFiles.deleteFileTrash(file.id) +await client.trashedFiles.deleteFileTrash(file.id); ``` ### Arguments - fileId `string` - - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" + - The unique identifier that represents a file. The ID for any file can be determined by visiting a file in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/files/123` the `file_id` is `123`. Example: "12345" - headers `DeleteFileTrashHeadersArg` - Headers of deleteFileTrash method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the file was permanently deleted. - - diff --git a/docs/trashedFolders.md b/docs/trashedFolders.md index db62877f..b4e92bb5 100644 --- a/docs/trashedFolders.md +++ b/docs/trashedFolders.md @@ -1,6 +1,5 @@ # TrashedFoldersManager - - [Restore folder](#restore-folder) - [Get trashed folder](#get-trashed-folder) - [Permanently remove folder](#permanently-remove-folder) @@ -27,14 +26,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-folders-id/). + ```ts -await client.trashedFolders.restoreFolderFromTrash(folder.id) +await client.trashedFolders.restoreFolderFromTrash(folder.id); ``` ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - requestBody `RestoreFolderFromTrashRequestBodyArg` - Request body of restoreFolderFromTrash method - queryParams `RestoreFolderFromTrashQueryParamsArg` @@ -42,14 +42,12 @@ await client.trashedFolders.restoreFolderFromTrash(folder.id) - headers `RestoreFolderFromTrashHeadersArg` - Headers of restoreFolderFromTrash method - ### Returns This function returns a value of type `TrashFolderRestored`. Returns a folder object when the folder has been restored. - ## Get trashed folder Retrieves a folder that has been moved to the trash. @@ -70,20 +68,20 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-id-trash/). + ```ts -await client.trashedFolders.getFolderTrash(folder.id) +await client.trashedFolders.getFolderTrash(folder.id); ``` ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - queryParams `GetFolderTrashQueryParamsArg` - Query parameters of getFolderTrash method - headers `GetFolderTrashHeadersArg` - Headers of getFolderTrash method - ### Returns This function returns a value of type `TrashFolder`. @@ -92,7 +90,6 @@ Returns the folder that was trashed, including information about when the it was moved to the trash. - ## Permanently remove folder Permanently deletes a folder that is in the trash. @@ -104,23 +101,21 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-folders-id-trash/). + ```ts -await client.trashedFolders.deleteFolderTrash(folder.id) +await client.trashedFolders.deleteFolderTrash(folder.id); ``` ### Arguments - folderId `string` - - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" + - The unique identifier that represent a folder. The ID for any folder can be determined by visiting this folder in the web application and copying the ID from the URL. For example, for the URL `https://*.app.box.com/folder/123` the `folder_id` is `123`. The root folder of a Box account is always represented by the ID `0`. Example: "12345" - headers `DeleteFolderTrashHeadersArg` - Headers of deleteFolderTrash method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the folder was permanently deleted. - - diff --git a/docs/trashedItems.md b/docs/trashedItems.md index cc52e955..54cc4a66 100644 --- a/docs/trashedItems.md +++ b/docs/trashedItems.md @@ -1,6 +1,5 @@ # TrashedItemsManager - - [List trashed items](#list-trashed-items) ## List trashed items @@ -20,7 +19,7 @@ This operation is performed by calling function `getFolderTrashItems`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-folders-trash-items/). -*Currently we don't have an example for calling `getFolderTrashItems` in integration tests* +_Currently we don't have an example for calling `getFolderTrashItems` in integration tests_ ### Arguments @@ -29,11 +28,8 @@ See the endpoint docs at - headers `GetFolderTrashItemsHeadersArg` - Headers of getFolderTrashItems method - ### Returns This function returns a value of type `Items`. Returns a list of items that have been deleted - - diff --git a/docs/trashedWebLinks.md b/docs/trashedWebLinks.md index 3abed439..8c3e2d2c 100644 --- a/docs/trashedWebLinks.md +++ b/docs/trashedWebLinks.md @@ -1,6 +1,5 @@ # TrashedWebLinksManager - - [Restore web link](#restore-web-link) - [Get trashed web link](#get-trashed-web-link) - [Permanently remove web link](#permanently-remove-web-link) @@ -9,7 +8,7 @@ Restores a web link that has been moved to the trash. -An optional new parent ID can be provided to restore the web link to in case +An optional new parent ID can be provided to restore the web link to in case the original folder has been deleted. This operation is performed by calling function `createWebLinkById`. @@ -17,7 +16,7 @@ This operation is performed by calling function `createWebLinkById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-web-links-id/). -*Currently we don't have an example for calling `createWebLinkById` in integration tests* +_Currently we don't have an example for calling `createWebLinkById` in integration tests_ ### Arguments @@ -30,14 +29,12 @@ See the endpoint docs at - headers `CreateWebLinkByIdHeadersArg` - Headers of createWebLinkById method - ### Returns This function returns a value of type `TrashWebLinkRestored`. Returns a web link object when it has been restored. - ## Get trashed web link Retrieves a web link that has been moved to the trash. @@ -47,7 +44,7 @@ This operation is performed by calling function `getWebLinkTrash`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-web-links-id-trash/). -*Currently we don't have an example for calling `getWebLinkTrash` in integration tests* +_Currently we don't have an example for calling `getWebLinkTrash` in integration tests_ ### Arguments @@ -58,7 +55,6 @@ See the endpoint docs at - headers `GetWebLinkTrashHeadersArg` - Headers of getWebLinkTrash method - ### Returns This function returns a value of type `TrashWebLink`. @@ -67,7 +63,6 @@ Returns the web link that was trashed, including information about when the it was moved to the trash. - ## Permanently remove web link Permanently deletes a web link that is in the trash. @@ -78,7 +73,7 @@ This operation is performed by calling function `deleteWebLinkTrash`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-web-links-id-trash/). -*Currently we don't have an example for calling `deleteWebLinkTrash` in integration tests* +_Currently we don't have an example for calling `deleteWebLinkTrash` in integration tests_ ### Arguments @@ -87,12 +82,9 @@ See the endpoint docs at - headers `DeleteWebLinkTrashHeadersArg` - Headers of deleteWebLinkTrash method - ### Returns This function returns a value of type `undefined`. Returns an empty response when the web link was permanently deleted. - - diff --git a/docs/userCollaborations.md b/docs/userCollaborations.md index ca3d4c15..bcb0ff22 100644 --- a/docs/userCollaborations.md +++ b/docs/userCollaborations.md @@ -1,6 +1,5 @@ # UserCollaborationsManager - - [Get collaboration](#get-collaboration) - [Update collaboration](#update-collaboration) - [Remove collaboration](#remove-collaboration) @@ -15,7 +14,7 @@ This operation is performed by calling function `getCollaborationById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-collaborations-id/). -*Currently we don't have an example for calling `getCollaborationById` in integration tests* +_Currently we don't have an example for calling `getCollaborationById` in integration tests_ ### Arguments @@ -26,14 +25,12 @@ See the endpoint docs at - headers `GetCollaborationByIdHeadersArg` - Headers of getCollaborationById method - ### Returns This function returns a value of type `Collaboration`. Returns a collaboration object. - ## Update collaboration Updates a collaboration. @@ -45,7 +42,7 @@ This operation is performed by calling function `updateCollaborationById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/put-collaborations-id/). -*Currently we don't have an example for calling `updateCollaborationById` in integration tests* +_Currently we don't have an example for calling `updateCollaborationById` in integration tests_ ### Arguments @@ -56,7 +53,6 @@ See the endpoint docs at - headers `UpdateCollaborationByIdHeadersArg` - Headers of updateCollaborationById method - ### Returns This function returns a value of type `Collaboration`. @@ -65,7 +61,6 @@ Returns an updated collaboration object unless the owner has changed.If the role and a new collaboration is created. The previous `owner` of the old collaboration will be a `co-owner` on the new collaboration. - ## Remove collaboration Deletes a single collaboration. @@ -75,7 +70,7 @@ This operation is performed by calling function `deleteCollaborationById`. See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-collaborations-id/). -*Currently we don't have an example for calling `deleteCollaborationById` in integration tests* +_Currently we don't have an example for calling `deleteCollaborationById` in integration tests_ ### Arguments @@ -84,7 +79,6 @@ See the endpoint docs at - headers `DeleteCollaborationByIdHeadersArg` - Headers of deleteCollaborationById method - ### Returns This function returns a value of type `undefined`. @@ -92,7 +86,6 @@ This function returns a value of type `undefined`. A blank response is returned if the collaboration was successfully deleted. - ## Create collaboration Adds a collaboration for a single user or a single group to a file @@ -106,16 +99,17 @@ this endpoint is dependent on the group's ability to be invited. If collaboration is in `pending` status, the following fields are redacted: + - `login` and `name` are hidden if a collaboration was created -using `user_id`, -- `name` is hidden if a collaboration was created using `login`. + using `user_id`, +- `name` is hidden if a collaboration was created using `login`. This operation is performed by calling function `createCollaboration`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-collaborations/). -*Currently we don't have an example for calling `createCollaboration` in integration tests* +_Currently we don't have an example for calling `createCollaboration` in integration tests_ ### Arguments @@ -126,11 +120,8 @@ See the endpoint docs at - headers `CreateCollaborationHeadersArg` - Headers of createCollaboration method - ### Returns This function returns a value of type `Collaboration`. Returns a new collaboration object. - - diff --git a/docs/users.md b/docs/users.md index af83db61..63699d62 100644 --- a/docs/users.md +++ b/docs/users.md @@ -1,6 +1,5 @@ # UsersManager - - [List enterprise users](#list-enterprise-users) - [Create user](#create-user) - [Get current user](#get-current-user) @@ -23,8 +22,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users/). + ```ts -await client.users.getUsers() +await client.users.getUsers(); ``` ### Arguments @@ -34,14 +34,12 @@ await client.users.getUsers() - headers `GetUsersHeadersArg` - Headers of getUsers method - ### Returns This function returns a value of type `Users`. Returns all of the users in the enterprise. - ## Create user Creates a new managed user in an enterprise. This endpoint @@ -54,8 +52,13 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-users/). + ```ts -await client.users.createUser({ name: userName, login: userLogin, isPlatformAccessOnly: true } satisfies CreateUserRequestBodyArg) +await client.users.createUser({ + name: userName, + login: userLogin, + isPlatformAccessOnly: true, +} satisfies CreateUserRequestBodyArg); ``` ### Arguments @@ -67,14 +70,12 @@ await client.users.createUser({ name: userName, login: userLogin, isPlatformAcce - headers `CreateUserHeadersArg` - Headers of createUser method - ### Returns This function returns a value of type `User`. Returns a user object for the newly created user. - ## Get current user Retrieves information about the user who is currently authenticated. @@ -94,8 +95,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users-me/). + ```ts -await client.users.getUserMe() +await client.users.getUserMe(); ``` ### Arguments @@ -105,14 +107,12 @@ await client.users.getUserMe() - headers `GetUserMeHeadersArg` - Headers of getUserMe method - ### Returns This function returns a value of type `UserFull`. Returns a single user object. - ## Get user Retrieves information about a user in the enterprise. @@ -133,8 +133,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-users-id/). + ```ts -await client.users.getUserById(user.id) +await client.users.getUserById(user.id); ``` ### Arguments @@ -146,7 +147,6 @@ await client.users.getUserById(user.id) - headers `GetUserByIdHeadersArg` - Headers of getUserById method - ### Returns This function returns a value of type `UserFull`. @@ -158,7 +158,6 @@ Not all available fields are returned by default. Use the any specific fields using the [fields](#get-users-id--request--fields) parameter. - ## Update user Updates a managed or app user in an enterprise. This endpoint @@ -171,8 +170,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-users-id/). + ```ts -await client.users.updateUserById(user.id, { name: updatedUserName } satisfies UpdateUserByIdRequestBodyArg) +await client.users.updateUserById(user.id, { + name: updatedUserName, +} satisfies UpdateUserByIdRequestBodyArg); ``` ### Arguments @@ -186,14 +188,12 @@ await client.users.updateUserById(user.id, { name: updatedUserName } satisfies U - headers `UpdateUserByIdHeadersArg` - Headers of updateUserById method - ### Returns This function returns a value of type `UserFull`. Returns the updated user object. - ## Delete user Deletes a user. By default this will fail if the user @@ -207,8 +207,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-users-id/). + ```ts -await client.users.deleteUserById(user.id) +await client.users.deleteUserById(user.id); ``` ### Arguments @@ -220,11 +221,8 @@ await client.users.deleteUserById(user.id) - headers `DeleteUserByIdHeadersArg` - Headers of deleteUserById method - ### Returns This function returns a value of type `undefined`. Removes the user and returns an empty response. - - diff --git a/docs/webLinks.md b/docs/webLinks.md index 5baa0f02..4a09a859 100644 --- a/docs/webLinks.md +++ b/docs/webLinks.md @@ -1,6 +1,5 @@ # WebLinksManager - - [Create web link](#create-web-link) - [Get web link](#get-web-link) - [Update web link](#update-web-link) @@ -16,8 +15,14 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-web-links/). + ```ts -await client.webLinks.createWebLink({ url: url, parent: parent, name: name, description: description } satisfies CreateWebLinkRequestBodyArg) +await client.webLinks.createWebLink({ + url: url, + parent: parent, + name: name, + description: description, +} satisfies CreateWebLinkRequestBodyArg); ``` ### Arguments @@ -27,14 +32,12 @@ await client.webLinks.createWebLink({ url: url, parent: parent, name: name, desc - headers `CreateWebLinkHeadersArg` - Headers of createWebLink method - ### Returns This function returns a value of type `WebLink`. Returns the newly created web link object. - ## Get web link Retrieve information about a web link. @@ -45,8 +48,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-web-links-id/). + ```ts -await client.webLinks.getWebLinkById(weblink.id) +await client.webLinks.getWebLinkById(weblink.id); ``` ### Arguments @@ -56,14 +60,12 @@ await client.webLinks.getWebLinkById(weblink.id) - headers `GetWebLinkByIdHeadersArg` - Headers of getWebLinkById method - ### Returns This function returns a value of type `WebLink`. Returns the web link object. - ## Update web link Updates a web link object. @@ -74,8 +76,15 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-web-links-id/). + ```ts -await client.webLinks.updateWebLinkById(weblink.id, { name: updatedName, sharedLink: { access: sharedAccess, password: password } satisfies UpdateWebLinkByIdRequestBodyArgSharedLinkField } satisfies UpdateWebLinkByIdRequestBodyArg) +await client.webLinks.updateWebLinkById(weblink.id, { + name: updatedName, + sharedLink: { + access: sharedAccess, + password: password, + } satisfies UpdateWebLinkByIdRequestBodyArgSharedLinkField, +} satisfies UpdateWebLinkByIdRequestBodyArg); ``` ### Arguments @@ -87,14 +96,12 @@ await client.webLinks.updateWebLinkById(weblink.id, { name: updatedName, sharedL - headers `UpdateWebLinkByIdHeadersArg` - Headers of updateWebLinkById method - ### Returns This function returns a value of type `WebLink`. Returns the updated web link object. - ## Remove web link Deletes a web link. @@ -105,8 +112,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-web-links-id/). + ```ts -await client.webLinks.deleteWebLinkById(weblink.id) +await client.webLinks.deleteWebLinkById(weblink.id); ``` ### Arguments @@ -116,12 +124,9 @@ await client.webLinks.deleteWebLinkById(weblink.id) - headers `DeleteWebLinkByIdHeadersArg` - Headers of deleteWebLinkById method - ### Returns This function returns a value of type `undefined`. An empty response will be returned when the web link was successfully deleted. - - diff --git a/docs/webhooks.md b/docs/webhooks.md index c91473bd..61d4750d 100644 --- a/docs/webhooks.md +++ b/docs/webhooks.md @@ -1,6 +1,5 @@ # WebhooksManager - - [List all webhooks](#list-all-webhooks) - [Create webhook](#create-webhook) - [Get webhook](#get-webhook) @@ -22,8 +21,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-webhooks/). + ```ts -await client.webhooks.getWebhooks() +await client.webhooks.getWebhooks(); ``` ### Arguments @@ -33,14 +33,12 @@ await client.webhooks.getWebhooks() - headers `GetWebhooksHeadersArg` - Headers of getWebhooks method - ### Returns This function returns a value of type `Webhooks`. Returns a list of webhooks. - ## Create webhook Creates a webhook. @@ -51,8 +49,16 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/post-webhooks/). + ```ts -await client.webhooks.createWebhook({ target: { id: folder.id, type: "folder" as CreateWebhookRequestBodyArgTargetFieldTypeField } satisfies CreateWebhookRequestBodyArgTargetField, address: "https://example.com/new-webhook", triggers: ["FILE.UPLOADED"] } satisfies CreateWebhookRequestBodyArg) +await client.webhooks.createWebhook({ + target: { + id: folder.id, + type: 'folder' as CreateWebhookRequestBodyArgTargetFieldTypeField, + } satisfies CreateWebhookRequestBodyArgTargetField, + address: 'https://example.com/new-webhook', + triggers: ['FILE.UPLOADED'], +} satisfies CreateWebhookRequestBodyArg); ``` ### Arguments @@ -62,14 +68,12 @@ await client.webhooks.createWebhook({ target: { id: folder.id, type: "folder" as - headers `CreateWebhookHeadersArg` - Headers of createWebhook method - ### Returns This function returns a value of type `Webhook`. Returns the new webhook object. - ## Get webhook Retrieves a specific webhook @@ -80,8 +84,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/get-webhooks-id/). + ```ts -await client.webhooks.getWebhookById(webhook.id) +await client.webhooks.getWebhookById(webhook.id); ``` ### Arguments @@ -91,14 +96,12 @@ await client.webhooks.getWebhookById(webhook.id) - headers `GetWebhookByIdHeadersArg` - Headers of getWebhookById method - ### Returns This function returns a value of type `Webhook`. Returns a webhook object - ## Update webhook Updates a webhook. @@ -109,8 +112,11 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/put-webhooks-id/). + ```ts -await client.webhooks.updateWebhookById(webhook.id, { address: "https://example.com/updated-webhook" } satisfies UpdateWebhookByIdRequestBodyArg) +await client.webhooks.updateWebhookById(webhook.id, { + address: 'https://example.com/updated-webhook', +} satisfies UpdateWebhookByIdRequestBodyArg); ``` ### Arguments @@ -122,14 +128,12 @@ await client.webhooks.updateWebhookById(webhook.id, { address: "https://example. - headers `UpdateWebhookByIdHeadersArg` - Headers of updateWebhookById method - ### Returns This function returns a value of type `Webhook`. Returns the new webhook object. - ## Remove webhook Deletes a webhook. @@ -140,8 +144,9 @@ See the endpoint docs at [API Reference](https://developer.box.com/reference/delete-webhooks-id/). + ```ts -await client.webhooks.deleteWebhookById(webhook.id) +await client.webhooks.deleteWebhookById(webhook.id); ``` ### Arguments @@ -151,12 +156,9 @@ await client.webhooks.deleteWebhookById(webhook.id) - headers `DeleteWebhookByIdHeadersArg` - Headers of deleteWebhookById method - ### Returns This function returns a value of type `undefined`. An empty response will be returned when the webhook was successfully deleted. - - diff --git a/docs/workflows.md b/docs/workflows.md index 78105fba..58548669 100644 --- a/docs/workflows.md +++ b/docs/workflows.md @@ -1,6 +1,5 @@ # WorkflowsManager - - [List workflows](#list-workflows) - [Starts workflow based on request body](#starts-workflow-based-on-request-body) @@ -17,7 +16,7 @@ This operation is performed by calling function `getWorkflows`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-workflows/). -*Currently we don't have an example for calling `getWorkflows` in integration tests* +_Currently we don't have an example for calling `getWorkflows` in integration tests_ ### Arguments @@ -26,14 +25,12 @@ See the endpoint docs at - headers `GetWorkflowsHeadersArg` - Headers of getWorkflows method - ### Returns This function returns a value of type `Workflows`. Returns the workflow. - ## Starts workflow based on request body Initiates a flow with a trigger type of `WORKFLOW_MANUAL_START`. @@ -46,7 +43,7 @@ This operation is performed by calling function `createWorkflowStart`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-workflows-id-start/). -*Currently we don't have an example for calling `createWorkflowStart` in integration tests* +_Currently we don't have an example for calling `createWorkflowStart` in integration tests_ ### Arguments @@ -57,11 +54,8 @@ See the endpoint docs at - headers `CreateWorkflowStartHeadersArg` - Headers of createWorkflowStart method - ### Returns This function returns a value of type `undefined`. Starts the workflow. - - diff --git a/docs/zipDownloads.md b/docs/zipDownloads.md index df89d16a..1c55f090 100644 --- a/docs/zipDownloads.md +++ b/docs/zipDownloads.md @@ -1,6 +1,5 @@ # ZipDownloadsManager - - [Create zip download](#create-zip-download) - [Download zip archive](#download-zip-archive) - [Get zip download status](#get-zip-download-status) @@ -29,7 +28,7 @@ This operation is performed by calling function `createZipDownload`. See the endpoint docs at [API Reference](https://developer.box.com/reference/post-zip-downloads/). -*Currently we don't have an example for calling `createZipDownload` in integration tests* +_Currently we don't have an example for calling `createZipDownload` in integration tests_ ### Arguments @@ -38,7 +37,6 @@ See the endpoint docs at - headers `CreateZipDownloadHeadersArg` - Headers of createZipDownload method - ### Returns This function returns a value of type `ZipDownload`. @@ -47,7 +45,6 @@ If the `zip` archive is ready to be downloaded, the API will return a response that will include a `download_url`, a `status_url`, as well as any conflicts that might have occurred when creating the request. - ## Download zip archive Returns the contents of a `zip` archive in binary format. This URL does not @@ -69,7 +66,7 @@ This operation is performed by calling function `getZipDownloadContent`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-zip-downloads-id-content/). -*Currently we don't have an example for calling `getZipDownloadContent` in integration tests* +_Currently we don't have an example for calling `getZipDownloadContent` in integration tests_ ### Arguments @@ -78,7 +75,6 @@ See the endpoint docs at - headers `GetZipDownloadContentHeadersArg` - Headers of getZipDownloadContent method - ### Returns This function returns a value of type `ByteStream`. @@ -86,7 +82,6 @@ This function returns a value of type `ByteStream`. Returns the content of the items requested for this download, formatted as a stream of files and folders in a `zip` archive. - ## Get zip download status Returns the download status of a `zip` archive, allowing an application to @@ -107,7 +102,7 @@ This operation is performed by calling function `getZipDownloadStatus`. See the endpoint docs at [API Reference](https://developer.box.com/reference/get-zip-downloads-id-status/). -*Currently we don't have an example for calling `getZipDownloadStatus` in integration tests* +_Currently we don't have an example for calling `getZipDownloadStatus` in integration tests_ ### Arguments @@ -116,11 +111,8 @@ See the endpoint docs at - headers `GetZipDownloadStatusHeadersArg` - Headers of getZipDownloadStatus method - ### Returns This function returns a value of type `ZipDownloadStatus`. Returns the status of the `zip` archive that is being downloaded. - - diff --git a/package.json b/package.json index 0d9f8865..4482164e 100644 --- a/package.json +++ b/package.json @@ -43,4 +43,4 @@ "files": [ "lib" ] -} \ No newline at end of file +} diff --git a/src/managers/files.generated.ts b/src/managers/files.generated.ts index b8848b9f..d787127c 100644 --- a/src/managers/files.generated.ts +++ b/src/managers/files.generated.ts @@ -275,7 +275,7 @@ export function deserializeUpdateFileByIdRequestBodyArgCollectionsField(val: any export function serializeUpdateFileByIdRequestBodyArg(val: UpdateFileByIdRequestBodyArg): Json { return { ["name"]: val.name == void 0 ? void 0 : val.name, ["description"]: val.description == void 0 ? void 0 : val.description, ["parent"]: val.parent == void 0 ? void 0 : serializeUpdateFileByIdRequestBodyArgParentField(val.parent), ["shared_link"]: val.sharedLink == void 0 ? void 0 : serializeUpdateFileByIdRequestBodyArgSharedLinkField(val.sharedLink), ["lock"]: val.lock == void 0 ? void 0 : serializeUpdateFileByIdRequestBodyArgLockField(val.lock), ["disposition_at"]: val.dispositionAt == void 0 ? void 0 : val.dispositionAt, ["permissions"]: val.permissions == void 0 ? void 0 : serializeUpdateFileByIdRequestBodyArgPermissionsField(val.permissions), ["collections"]: val.collections == void 0 ? void 0 : val.collections.map(function (item: UpdateFileByIdRequestBodyArgCollectionsField): any { return serializeUpdateFileByIdRequestBodyArgCollectionsField(item); - }) as readonly any[], ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): string { + }) as readonly any[], ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): any { return item; }) as readonly any[] }; } @@ -290,7 +290,7 @@ export function deserializeUpdateFileByIdRequestBodyArg(val: any): UpdateFileByI const collections: undefined | readonly UpdateFileByIdRequestBodyArgCollectionsField[] = val.collections == void 0 ? void 0 : isJson(val.collections, "array") ? val.collections.map(function (itm: Json): any { return deserializeUpdateFileByIdRequestBodyArgCollectionsField(itm); }) as readonly any[] : []; - const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): Json { + const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): any { return itm; }) as readonly any[] : []; return { name: name, description: description, parent: parent, sharedLink: sharedLink, lock: lock, dispositionAt: dispositionAt, permissions: permissions, collections: collections, tags: tags } satisfies UpdateFileByIdRequestBodyArg; diff --git a/src/managers/folders.generated.ts b/src/managers/folders.generated.ts index 807f50ea..0df013c3 100644 --- a/src/managers/folders.generated.ts +++ b/src/managers/folders.generated.ts @@ -320,7 +320,7 @@ export function deserializeUpdateFolderByIdRequestBodyArgCollectionsField(val: a return { id: id, type: type } satisfies UpdateFolderByIdRequestBodyArgCollectionsField; } export function serializeUpdateFolderByIdRequestBodyArg(val: UpdateFolderByIdRequestBodyArg): Json { - return { ["name"]: val.name == void 0 ? void 0 : val.name, ["description"]: val.description == void 0 ? void 0 : val.description, ["sync_state"]: val.syncState == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgSyncStateField(val.syncState), ["can_non_owners_invite"]: val.canNonOwnersInvite == void 0 ? void 0 : val.canNonOwnersInvite, ["parent"]: val.parent == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgParentField(val.parent), ["shared_link"]: val.sharedLink == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgSharedLinkField(val.sharedLink), ["folder_upload_email"]: val.folderUploadEmail == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgFolderUploadEmailField(val.folderUploadEmail), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): string { + return { ["name"]: val.name == void 0 ? void 0 : val.name, ["description"]: val.description == void 0 ? void 0 : val.description, ["sync_state"]: val.syncState == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgSyncStateField(val.syncState), ["can_non_owners_invite"]: val.canNonOwnersInvite == void 0 ? void 0 : val.canNonOwnersInvite, ["parent"]: val.parent == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgParentField(val.parent), ["shared_link"]: val.sharedLink == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgSharedLinkField(val.sharedLink), ["folder_upload_email"]: val.folderUploadEmail == void 0 ? void 0 : serializeUpdateFolderByIdRequestBodyArgFolderUploadEmailField(val.folderUploadEmail), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): any { return item; }) as readonly any[], ["is_collaboration_restricted_to_enterprise"]: val.isCollaborationRestrictedToEnterprise == void 0 ? void 0 : val.isCollaborationRestrictedToEnterprise, ["collections"]: val.collections == void 0 ? void 0 : val.collections.map(function (item: UpdateFolderByIdRequestBodyArgCollectionsField): any { return serializeUpdateFolderByIdRequestBodyArgCollectionsField(item); @@ -334,7 +334,7 @@ export function deserializeUpdateFolderByIdRequestBodyArg(val: any): UpdateFolde const parent: undefined | UpdateFolderByIdRequestBodyArgParentField = val.parent == void 0 ? void 0 : deserializeUpdateFolderByIdRequestBodyArgParentField(val.parent); const sharedLink: undefined | UpdateFolderByIdRequestBodyArgSharedLinkField = val.shared_link == void 0 ? void 0 : deserializeUpdateFolderByIdRequestBodyArgSharedLinkField(val.shared_link); const folderUploadEmail: undefined | UpdateFolderByIdRequestBodyArgFolderUploadEmailField = val.folder_upload_email == void 0 ? void 0 : deserializeUpdateFolderByIdRequestBodyArgFolderUploadEmailField(val.folder_upload_email); - const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): Json { + const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const isCollaborationRestrictedToEnterprise: undefined | boolean = val.is_collaboration_restricted_to_enterprise == void 0 ? void 0 : val.is_collaboration_restricted_to_enterprise; diff --git a/src/managers/metadataTemplates.generated.ts b/src/managers/metadataTemplates.generated.ts index d911c5a0..8b97b0ca 100644 --- a/src/managers/metadataTemplates.generated.ts +++ b/src/managers/metadataTemplates.generated.ts @@ -281,11 +281,11 @@ export function deserializeUpdateMetadataTemplateSchemaRequestBodyArgOpField(val throw "".concat("Invalid value: ", val) as string; } export function serializeUpdateMetadataTemplateSchemaRequestBodyArg(val: UpdateMetadataTemplateSchemaRequestBodyArg): Json { - return { ["op"]: serializeUpdateMetadataTemplateSchemaRequestBodyArgOpField(val.op), ["data"]: val.data == void 0 ? void 0 : val.data, ["fieldKey"]: val.fieldKey == void 0 ? void 0 : val.fieldKey, ["fieldKeys"]: val.fieldKeys == void 0 ? void 0 : val.fieldKeys.map(function (item: string): string { + return { ["op"]: serializeUpdateMetadataTemplateSchemaRequestBodyArgOpField(val.op), ["data"]: val.data == void 0 ? void 0 : val.data, ["fieldKey"]: val.fieldKey == void 0 ? void 0 : val.fieldKey, ["fieldKeys"]: val.fieldKeys == void 0 ? void 0 : val.fieldKeys.map(function (item: string): any { return item; - }) as readonly any[], ["enumOptionKey"]: val.enumOptionKey == void 0 ? void 0 : val.enumOptionKey, ["enumOptionKeys"]: val.enumOptionKeys == void 0 ? void 0 : val.enumOptionKeys.map(function (item: string): string { + }) as readonly any[], ["enumOptionKey"]: val.enumOptionKey == void 0 ? void 0 : val.enumOptionKey, ["enumOptionKeys"]: val.enumOptionKeys == void 0 ? void 0 : val.enumOptionKeys.map(function (item: string): any { return item; - }) as readonly any[], ["multiSelectOptionKey"]: val.multiSelectOptionKey == void 0 ? void 0 : val.multiSelectOptionKey, ["multiSelectOptionKeys"]: val.multiSelectOptionKeys == void 0 ? void 0 : val.multiSelectOptionKeys.map(function (item: string): string { + }) as readonly any[], ["multiSelectOptionKey"]: val.multiSelectOptionKey == void 0 ? void 0 : val.multiSelectOptionKey, ["multiSelectOptionKeys"]: val.multiSelectOptionKeys == void 0 ? void 0 : val.multiSelectOptionKeys.map(function (item: string): any { return item; }) as readonly any[] }; } @@ -295,15 +295,15 @@ export function deserializeUpdateMetadataTemplateSchemaRequestBodyArg(val: any): readonly [key: string]: string; } = val.data == void 0 ? void 0 : val.data; const fieldKey: undefined | string = val.fieldKey == void 0 ? void 0 : val.fieldKey; - const fieldKeys: undefined | readonly string[] = val.fieldKeys == void 0 ? void 0 : isJson(val.fieldKeys, "array") ? val.fieldKeys.map(function (itm: Json): Json { + const fieldKeys: undefined | readonly string[] = val.fieldKeys == void 0 ? void 0 : isJson(val.fieldKeys, "array") ? val.fieldKeys.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const enumOptionKey: undefined | string = val.enumOptionKey == void 0 ? void 0 : val.enumOptionKey; - const enumOptionKeys: undefined | readonly string[] = val.enumOptionKeys == void 0 ? void 0 : isJson(val.enumOptionKeys, "array") ? val.enumOptionKeys.map(function (itm: Json): Json { + const enumOptionKeys: undefined | readonly string[] = val.enumOptionKeys == void 0 ? void 0 : isJson(val.enumOptionKeys, "array") ? val.enumOptionKeys.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const multiSelectOptionKey: undefined | string = val.multiSelectOptionKey == void 0 ? void 0 : val.multiSelectOptionKey; - const multiSelectOptionKeys: undefined | readonly string[] = val.multiSelectOptionKeys == void 0 ? void 0 : isJson(val.multiSelectOptionKeys, "array") ? val.multiSelectOptionKeys.map(function (itm: Json): Json { + const multiSelectOptionKeys: undefined | readonly string[] = val.multiSelectOptionKeys == void 0 ? void 0 : isJson(val.multiSelectOptionKeys, "array") ? val.multiSelectOptionKeys.map(function (itm: Json): any { return itm; }) as readonly any[] : []; return { op: op, data: data, fieldKey: fieldKey, fieldKeys: fieldKeys, enumOptionKey: enumOptionKey, enumOptionKeys: enumOptionKeys, multiSelectOptionKey: multiSelectOptionKey, multiSelectOptionKeys: multiSelectOptionKeys } satisfies UpdateMetadataTemplateSchemaRequestBodyArg; diff --git a/src/managers/sessionTermination.generated.ts b/src/managers/sessionTermination.generated.ts index c2eddcfa..81c21133 100644 --- a/src/managers/sessionTermination.generated.ts +++ b/src/managers/sessionTermination.generated.ts @@ -61,28 +61,28 @@ export class SessionTerminationManager { } } export function serializeCreateUserTerminateSessionRequestBodyArg(val: CreateUserTerminateSessionRequestBodyArg): Json { - return { ["user_ids"]: val.userIds.map(function (item: string): string { + return { ["user_ids"]: val.userIds.map(function (item: string): any { return item; - }) as readonly any[], ["user_logins"]: val.userLogins.map(function (item: string): string { + }) as readonly any[], ["user_logins"]: val.userLogins.map(function (item: string): any { return item; }) as readonly any[] }; } export function deserializeCreateUserTerminateSessionRequestBodyArg(val: any): CreateUserTerminateSessionRequestBodyArg { - const userIds: readonly string[] = isJson(val.user_ids, "array") ? val.user_ids.map(function (itm: Json): Json { + const userIds: readonly string[] = isJson(val.user_ids, "array") ? val.user_ids.map(function (itm: Json): any { return itm; }) as readonly any[] : []; - const userLogins: readonly string[] = isJson(val.user_logins, "array") ? val.user_logins.map(function (itm: Json): Json { + const userLogins: readonly string[] = isJson(val.user_logins, "array") ? val.user_logins.map(function (itm: Json): any { return itm; }) as readonly any[] : []; return { userIds: userIds, userLogins: userLogins } satisfies CreateUserTerminateSessionRequestBodyArg; } export function serializeCreateGroupTerminateSessionRequestBodyArg(val: CreateGroupTerminateSessionRequestBodyArg): Json { - return { ["group_ids"]: val.groupIds.map(function (item: string): string { + return { ["group_ids"]: val.groupIds.map(function (item: string): any { return item; }) as readonly any[] }; } export function deserializeCreateGroupTerminateSessionRequestBodyArg(val: any): CreateGroupTerminateSessionRequestBodyArg { - const groupIds: readonly string[] = isJson(val.group_ids, "array") ? val.group_ids.map(function (itm: Json): Json { + const groupIds: readonly string[] = isJson(val.group_ids, "array") ? val.group_ids.map(function (itm: Json): any { return itm; }) as readonly any[] : []; return { groupIds: groupIds } satisfies CreateGroupTerminateSessionRequestBodyArg; diff --git a/src/schemas.generated.ts b/src/schemas.generated.ts index 8d0f00ea..bd93c6d1 100644 --- a/src/schemas.generated.ts +++ b/src/schemas.generated.ts @@ -3017,7 +3017,7 @@ export function deserializeMetadataQueryOrderByField(val: any): MetadataQueryOrd export function serializeMetadataQuery(val: MetadataQuery): Json { return { ["from"]: val.from, ["query"]: val.query == void 0 ? void 0 : val.query, ["query_params"]: val.queryParams == void 0 ? void 0 : val.queryParams, ["ancestor_folder_id"]: val.ancestorFolderId, ["order_by"]: val.orderBy == void 0 ? void 0 : val.orderBy.map(function (item: MetadataQueryOrderByField): any { return serializeMetadataQueryOrderByField(item); - }) as readonly any[], ["limit"]: val.limit == void 0 ? void 0 : val.limit, ["marker"]: val.marker == void 0 ? void 0 : val.marker, ["fields"]: val.fields == void 0 ? void 0 : val.fields.map(function (item: string): string { + }) as readonly any[], ["limit"]: val.limit == void 0 ? void 0 : val.limit, ["marker"]: val.marker == void 0 ? void 0 : val.marker, ["fields"]: val.fields == void 0 ? void 0 : val.fields.map(function (item: string): any { return item; }) as readonly any[] }; } @@ -3033,7 +3033,7 @@ export function deserializeMetadataQuery(val: any): MetadataQuery { }) as readonly any[] : []; const limit: undefined | number = val.limit == void 0 ? void 0 : val.limit; const marker: undefined | string = val.marker == void 0 ? void 0 : val.marker; - const fields: undefined | readonly string[] = val.fields == void 0 ? void 0 : isJson(val.fields, "array") ? val.fields.map(function (itm: Json): Json { + const fields: undefined | readonly string[] = val.fields == void 0 ? void 0 : isJson(val.fields, "array") ? val.fields.map(function (itm: Json): any { return itm; }) as readonly any[] : []; return { from: from, query: query, queryParams: queryParams, ancestorFolderId: ancestorFolderId, orderBy: orderBy, limit: limit, marker: marker, fields: fields } satisfies MetadataQuery; @@ -6870,7 +6870,7 @@ export function serializeFileFull(val: FileFull): Json { if (!isJson(base, "object")) { throw "Expecting an object for \"FileFull\""; } - return { ...base, ...{ ["version_number"]: val.versionNumber == void 0 ? void 0 : val.versionNumber, ["comment_count"]: val.commentCount == void 0 ? void 0 : val.commentCount, ["permissions"]: val.permissions == void 0 ? void 0 : serializeFileFullPermissionsField(val.permissions), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): string { + return { ...base, ...{ ["version_number"]: val.versionNumber == void 0 ? void 0 : val.versionNumber, ["comment_count"]: val.commentCount == void 0 ? void 0 : val.commentCount, ["permissions"]: val.permissions == void 0 ? void 0 : serializeFileFullPermissionsField(val.permissions), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): any { return item; }) as readonly any[], ["lock"]: val.lock == void 0 ? void 0 : serializeFileFullLockField(val.lock), ["extension"]: val.extension == void 0 ? void 0 : val.extension, ["is_package"]: val.isPackage == void 0 ? void 0 : val.isPackage, ["expiring_embed_link"]: val.expiringEmbedLink == void 0 ? void 0 : serializeFileFullExpiringEmbedLinkField(val.expiringEmbedLink), ["watermark_info"]: val.watermarkInfo == void 0 ? void 0 : serializeFileFullWatermarkInfoField(val.watermarkInfo), ["is_accessible_via_shared_link"]: val.isAccessibleViaSharedLink == void 0 ? void 0 : val.isAccessibleViaSharedLink, ["allowed_invitee_roles"]: val.allowedInviteeRoles == void 0 ? void 0 : val.allowedInviteeRoles.map(function (item: FileFullAllowedInviteeRolesField): any { return serializeFileFullAllowedInviteeRolesField(item); @@ -6882,7 +6882,7 @@ export function deserializeFileFull(val: any): FileFull { const versionNumber: undefined | string = val.version_number == void 0 ? void 0 : val.version_number; const commentCount: undefined | number = val.comment_count == void 0 ? void 0 : val.comment_count; const permissions: undefined | FileFullPermissionsField = val.permissions == void 0 ? void 0 : deserializeFileFullPermissionsField(val.permissions); - const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): Json { + const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const lock: undefined | FileFullLockField = val.lock == void 0 ? void 0 : deserializeFileFullLockField(val.lock); @@ -8690,7 +8690,7 @@ export function serializeFolderFull(val: FolderFull): Json { if (!isJson(base, "object")) { throw "Expecting an object for \"FolderFull\""; } - return { ...base, ...{ ["sync_state"]: val.syncState == void 0 ? void 0 : serializeFolderFullSyncStateField(val.syncState), ["has_collaborations"]: val.hasCollaborations == void 0 ? void 0 : val.hasCollaborations, ["permissions"]: val.permissions == void 0 ? void 0 : serializeFolderFullPermissionsField(val.permissions), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): string { + return { ...base, ...{ ["sync_state"]: val.syncState == void 0 ? void 0 : serializeFolderFullSyncStateField(val.syncState), ["has_collaborations"]: val.hasCollaborations == void 0 ? void 0 : val.hasCollaborations, ["permissions"]: val.permissions == void 0 ? void 0 : serializeFolderFullPermissionsField(val.permissions), ["tags"]: val.tags == void 0 ? void 0 : val.tags.map(function (item: string): any { return item; }) as readonly any[], ["can_non_owners_invite"]: val.canNonOwnersInvite == void 0 ? void 0 : val.canNonOwnersInvite, ["is_externally_owned"]: val.isExternallyOwned == void 0 ? void 0 : val.isExternallyOwned, ["metadata"]: val.metadata == void 0 ? void 0 : serializeFolderFullMetadataField(val.metadata), ["is_collaboration_restricted_to_enterprise"]: val.isCollaborationRestrictedToEnterprise == void 0 ? void 0 : val.isCollaborationRestrictedToEnterprise, ["allowed_shared_link_access_levels"]: val.allowedSharedLinkAccessLevels == void 0 ? void 0 : val.allowedSharedLinkAccessLevels.map(function (item: FolderFullAllowedSharedLinkAccessLevelsField): any { return serializeFolderFullAllowedSharedLinkAccessLevelsField(item); @@ -8702,7 +8702,7 @@ export function deserializeFolderFull(val: any): FolderFull { const syncState: undefined | FolderFullSyncStateField = val.sync_state == void 0 ? void 0 : deserializeFolderFullSyncStateField(val.sync_state); const hasCollaborations: undefined | boolean = val.has_collaborations == void 0 ? void 0 : val.has_collaborations; const permissions: undefined | FolderFullPermissionsField = val.permissions == void 0 ? void 0 : deserializeFolderFullPermissionsField(val.permissions); - const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): Json { + const tags: undefined | readonly string[] = val.tags == void 0 ? void 0 : isJson(val.tags, "array") ? val.tags.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const canNonOwnersInvite: undefined | boolean = val.can_non_owners_invite == void 0 ? void 0 : val.can_non_owners_invite; @@ -9662,7 +9662,7 @@ export function deserializeZipDownloadNameConflictsField(val: any): ZipDownloadN return { id: id, type: type, originalName: originalName, downloadName: downloadName } satisfies ZipDownloadNameConflictsField; } export function serializeZipDownload(val: ZipDownload): Json { - return { ["download_url"]: val.downloadUrl == void 0 ? void 0 : val.downloadUrl, ["status_url"]: val.statusUrl == void 0 ? void 0 : val.statusUrl, ["expires_at"]: val.expiresAt == void 0 ? void 0 : val.expiresAt, ["name_conflicts"]: val.nameConflicts == void 0 ? void 0 : val.nameConflicts.map(function (item: readonly ZipDownloadNameConflictsField[]): readonly any[] { + return { ["download_url"]: val.downloadUrl == void 0 ? void 0 : val.downloadUrl, ["status_url"]: val.statusUrl == void 0 ? void 0 : val.statusUrl, ["expires_at"]: val.expiresAt == void 0 ? void 0 : val.expiresAt, ["name_conflicts"]: val.nameConflicts == void 0 ? void 0 : val.nameConflicts.map(function (item: readonly ZipDownloadNameConflictsField[]): any { return item.map(function (item: ZipDownloadNameConflictsField): any { return serializeZipDownloadNameConflictsField(item); }) as readonly any[]; @@ -10748,7 +10748,7 @@ export function serializeTemplateSignerInput(val: TemplateSignerInput): Json { if (!isJson(base, "object")) { throw "Expecting an object for \"TemplateSignerInput\""; } - return { ...base, ...{ ["type"]: val.type == void 0 ? void 0 : serializeTemplateSignerInputTypeField(val.type), ["content_type"]: val.contentType == void 0 ? void 0 : serializeTemplateSignerInputContentTypeField(val.contentType), ["is_required"]: val.isRequired == void 0 ? void 0 : val.isRequired, ["page_index"]: val.pageIndex, ["document_id"]: val.documentId == void 0 ? void 0 : val.documentId, ["dropdown_choices"]: val.dropdownChoices == void 0 ? void 0 : val.dropdownChoices.map(function (item: string): string { + return { ...base, ...{ ["type"]: val.type == void 0 ? void 0 : serializeTemplateSignerInputTypeField(val.type), ["content_type"]: val.contentType == void 0 ? void 0 : serializeTemplateSignerInputContentTypeField(val.contentType), ["is_required"]: val.isRequired == void 0 ? void 0 : val.isRequired, ["page_index"]: val.pageIndex, ["document_id"]: val.documentId == void 0 ? void 0 : val.documentId, ["dropdown_choices"]: val.dropdownChoices == void 0 ? void 0 : val.dropdownChoices.map(function (item: string): any { return item; }) as readonly any[], ["group_id"]: val.groupId == void 0 ? void 0 : val.groupId, ["coordinates"]: val.coordinates == void 0 ? void 0 : serializeTemplateSignerInputCoordinatesField(val.coordinates), ["dimensions"]: val.dimensions == void 0 ? void 0 : serializeTemplateSignerInputDimensionsField(val.dimensions) } }; } @@ -10758,7 +10758,7 @@ export function deserializeTemplateSignerInput(val: any): TemplateSignerInput { const isRequired: undefined | boolean = val.is_required == void 0 ? void 0 : val.is_required; const pageIndex: number = val.page_index; const documentId: undefined | string = val.document_id == void 0 ? void 0 : val.document_id; - const dropdownChoices: undefined | readonly string[] = val.dropdown_choices == void 0 ? void 0 : isJson(val.dropdown_choices, "array") ? val.dropdown_choices.map(function (itm: Json): Json { + const dropdownChoices: undefined | readonly string[] = val.dropdown_choices == void 0 ? void 0 : isJson(val.dropdown_choices, "array") ? val.dropdown_choices.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const groupId: undefined | string = val.group_id == void 0 ? void 0 : val.group_id; @@ -10843,7 +10843,7 @@ export function deserializeSignTemplateAdditionalInfoFieldRequiredFieldSignersFi throw "".concat("Invalid value: ", val) as string; } export function serializeSignTemplateAdditionalInfoFieldRequiredField(val: SignTemplateAdditionalInfoFieldRequiredField): Json { - return { ["signers"]: val.signers == void 0 ? void 0 : val.signers.map(function (item: readonly SignTemplateAdditionalInfoFieldRequiredFieldSignersField[]): readonly any[] { + return { ["signers"]: val.signers == void 0 ? void 0 : val.signers.map(function (item: readonly SignTemplateAdditionalInfoFieldRequiredFieldSignersField[]): any { return item.map(function (item: SignTemplateAdditionalInfoFieldRequiredFieldSignersField): any { return serializeSignTemplateAdditionalInfoFieldRequiredFieldSignersField(item); }) as readonly any[]; @@ -11041,7 +11041,7 @@ export function serializeUserFull(val: UserFull): Json { } return { ...base, ...{ ["role"]: val.role == void 0 ? void 0 : serializeUserFullRoleField(val.role), ["tracking_codes"]: val.trackingCodes == void 0 ? void 0 : val.trackingCodes.map(function (item: TrackingCode): any { return serializeTrackingCode(item); - }) as readonly any[], ["can_see_managed_users"]: val.canSeeManagedUsers == void 0 ? void 0 : val.canSeeManagedUsers, ["is_sync_enabled"]: val.isSyncEnabled == void 0 ? void 0 : val.isSyncEnabled, ["is_external_collab_restricted"]: val.isExternalCollabRestricted == void 0 ? void 0 : val.isExternalCollabRestricted, ["is_exempt_from_device_limits"]: val.isExemptFromDeviceLimits == void 0 ? void 0 : val.isExemptFromDeviceLimits, ["is_exempt_from_login_verification"]: val.isExemptFromLoginVerification == void 0 ? void 0 : val.isExemptFromLoginVerification, ["enterprise"]: val.enterprise == void 0 ? void 0 : serializeUserFullEnterpriseField(val.enterprise), ["my_tags"]: val.myTags == void 0 ? void 0 : val.myTags.map(function (item: string): string { + }) as readonly any[], ["can_see_managed_users"]: val.canSeeManagedUsers == void 0 ? void 0 : val.canSeeManagedUsers, ["is_sync_enabled"]: val.isSyncEnabled == void 0 ? void 0 : val.isSyncEnabled, ["is_external_collab_restricted"]: val.isExternalCollabRestricted == void 0 ? void 0 : val.isExternalCollabRestricted, ["is_exempt_from_device_limits"]: val.isExemptFromDeviceLimits == void 0 ? void 0 : val.isExemptFromDeviceLimits, ["is_exempt_from_login_verification"]: val.isExemptFromLoginVerification == void 0 ? void 0 : val.isExemptFromLoginVerification, ["enterprise"]: val.enterprise == void 0 ? void 0 : serializeUserFullEnterpriseField(val.enterprise), ["my_tags"]: val.myTags == void 0 ? void 0 : val.myTags.map(function (item: string): any { return item; }) as readonly any[], ["hostname"]: val.hostname == void 0 ? void 0 : val.hostname, ["is_platform_access_only"]: val.isPlatformAccessOnly == void 0 ? void 0 : val.isPlatformAccessOnly, ["external_app_user_id"]: val.externalAppUserId == void 0 ? void 0 : val.externalAppUserId } }; } @@ -11056,7 +11056,7 @@ export function deserializeUserFull(val: any): UserFull { const isExemptFromDeviceLimits: undefined | boolean = val.is_exempt_from_device_limits == void 0 ? void 0 : val.is_exempt_from_device_limits; const isExemptFromLoginVerification: undefined | boolean = val.is_exempt_from_login_verification == void 0 ? void 0 : val.is_exempt_from_login_verification; const enterprise: undefined | UserFullEnterpriseField = val.enterprise == void 0 ? void 0 : deserializeUserFullEnterpriseField(val.enterprise); - const myTags: undefined | readonly string[] = val.my_tags == void 0 ? void 0 : isJson(val.my_tags, "array") ? val.my_tags.map(function (itm: Json): Json { + const myTags: undefined | readonly string[] = val.my_tags == void 0 ? void 0 : isJson(val.my_tags, "array") ? val.my_tags.map(function (itm: Json): any { return itm; }) as readonly any[] : []; const hostname: undefined | string = val.hostname == void 0 ? void 0 : val.hostname; @@ -11130,8 +11130,8 @@ export function serializeMetadataFieldFilterMultiSelect(val: MetadataFieldFilter return Object.fromEntries(Object.entries(val).map(([k, v]: [ string, any - ]) => [k, function (v: any): readonly any[] { - return v.map(function (item: string): string { + ]) => [k, function (v: any): any { + return v.map(function (item: string): any { return item; }) as readonly any[]; }(v)])) as { @@ -11145,9 +11145,7 @@ export function serializeMetadataFieldFilterFloatRange(val: MetadataFieldFilterF return Object.fromEntries(Object.entries(val).map(([k, v]: [ string, any - ]) => [k, function (v: any): { - readonly [key: string]: any; - } { + ]) => [k, function (v: any): any { return { ["lt"]: v.lt == void 0 ? void 0 : v.lt, ["gt"]: v.gt == void 0 ? void 0 : v.gt }; }(v)])) as { readonly [key: string]: any; @@ -11160,9 +11158,7 @@ export function serializeMetadataFieldFilterDateRange(val: MetadataFieldFilterDa return Object.fromEntries(Object.entries(val).map(([k, v]: [ string, any - ]) => [k, function (v: any): { - readonly [key: string]: any; - } { + ]) => [k, function (v: any): any { return { ["lt"]: v.lt == void 0 ? void 0 : v.lt, ["gt"]: v.gt == void 0 ? void 0 : v.gt }; }(v)])) as { readonly [key: string]: any; diff --git a/src/test/avatars.generated.test.ts b/src/test/avatars.generated.test.ts index 533fd9bc..7fed493c 100644 --- a/src/test/avatars.generated.test.ts +++ b/src/test/avatars.generated.test.ts @@ -1,3 +1,9 @@ +import { serializeUserFull } from "../schemas.generated.js"; +import { deserializeUserFull } from "../schemas.generated.js"; +import { serializeUserAvatar } from "../schemas.generated.js"; +import { deserializeUserAvatar } from "../schemas.generated.js"; +import { UserFull } from "../schemas.generated.js"; +import { UserAvatar } from "../schemas.generated.js"; import { CreateUserAvatarRequestBodyArg } from "../managers/avatars.generated.js"; import { decodeBase64ByteStream } from "../utils.js"; import { decodeBase64 } from "../utils.js"; diff --git a/src/test/chunkedUploads.generated.test.ts b/src/test/chunkedUploads.generated.test.ts index d0207da2..d7e15980 100644 --- a/src/test/chunkedUploads.generated.test.ts +++ b/src/test/chunkedUploads.generated.test.ts @@ -1,13 +1,30 @@ +import { serializeUploadSession } from "../schemas.generated.js"; +import { deserializeUploadSession } from "../schemas.generated.js"; import { serializeCreateFileUploadSessionRequestBodyArg } from "../managers/chunkedUploads.generated.js"; import { deserializeCreateFileUploadSessionRequestBodyArg } from "../managers/chunkedUploads.generated.js"; +import { serializeUploadedPart } from "../schemas.generated.js"; +import { deserializeUploadedPart } from "../schemas.generated.js"; +import { serializeUploadParts } from "../schemas.generated.js"; +import { deserializeUploadParts } from "../schemas.generated.js"; +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeCreateFileUploadSessionCommitRequestBodyArg } from "../managers/chunkedUploads.generated.js"; import { deserializeCreateFileUploadSessionCommitRequestBodyArg } from "../managers/chunkedUploads.generated.js"; +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; import { serializeUploadPart } from "../schemas.generated.js"; import { deserializeUploadPart } from "../schemas.generated.js"; +import { UploadSession } from "../schemas.generated.js"; import { CreateFileUploadSessionRequestBodyArg } from "../managers/chunkedUploads.generated.js"; +import { AsyncIterator } from "../utils.js"; +import { Buffer } from "../utils.js"; +import { UploadedPart } from "../schemas.generated.js"; import { UploadFilePartHeadersArg } from "../managers/chunkedUploads.generated.js"; +import { UploadParts } from "../schemas.generated.js"; +import { Files } from "../schemas.generated.js"; import { CreateFileUploadSessionCommitRequestBodyArg } from "../managers/chunkedUploads.generated.js"; import { CreateFileUploadSessionCommitHeadersArg } from "../managers/chunkedUploads.generated.js"; +import { File } from "../schemas.generated.js"; import { ByteStream } from "../utils.js"; import { cloneByteStream } from "../utils.js"; import { createHash } from "../utils.js"; @@ -21,6 +38,7 @@ import { readByteStream } from "../utils.js"; import { reduceIterator } from "../utils.js"; import { Hash } from "../utils.js"; import { listConcat } from "../utils.js"; +import { bufferLength } from "../utils.js"; import { Client } from "../client.generated.js"; import { JwtAuth } from "../jwtAuth.js"; import { JwtConfig } from "../jwtAuth.js"; @@ -57,7 +75,7 @@ export async function upload(client: Client): Promise { hash.updateHash(chunkBuffer) const sha1: any = hash.digestHash("base64"); const digest: any = "".concat("sha=", sha1) as string; - const chunkSize: any = chunkBuffer.length; + const chunkSize: any = bufferLength(chunkBuffer); const bytesStart: any = lastIndex + 1; const bytesEnd: any = lastIndex + chunkSize; const contentRange: any = "".concat("bytes ", bytesStart, "-", bytesEnd, "/", fileSize) as string; diff --git a/src/test/collections.generated.test.ts b/src/test/collections.generated.test.ts index 7006801b..29957e92 100644 --- a/src/test/collections.generated.test.ts +++ b/src/test/collections.generated.test.ts @@ -1,9 +1,21 @@ +import { serializeCollections } from "../schemas.generated.js"; +import { deserializeCollections } from "../schemas.generated.js"; +import { serializeCollection } from "../schemas.generated.js"; +import { deserializeCollection } from "../schemas.generated.js"; +import { serializeItems } from "../schemas.generated.js"; +import { deserializeItems } from "../schemas.generated.js"; +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { serializeUpdateFolderByIdRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeUpdateFolderByIdRequestBodyArg } from "../managers/folders.generated.js"; +import { Collections } from "../schemas.generated.js"; +import { Collection } from "../schemas.generated.js"; +import { Items } from "../schemas.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { UpdateFolderByIdRequestBodyArg } from "../managers/folders.generated.js"; diff --git a/src/test/comments.generated.test.ts b/src/test/comments.generated.test.ts index 26fcac98..b3a2fab6 100644 --- a/src/test/comments.generated.test.ts +++ b/src/test/comments.generated.test.ts @@ -1,7 +1,13 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeComments } from "../schemas.generated.js"; +import { deserializeComments } from "../schemas.generated.js"; +import { serializeComment } from "../schemas.generated.js"; +import { deserializeComment } from "../schemas.generated.js"; import { serializeCreateCommentRequestBodyArg } from "../managers/comments.generated.js"; import { deserializeCreateCommentRequestBodyArg } from "../managers/comments.generated.js"; import { serializeCreateCommentRequestBodyArgItemField } from "../managers/comments.generated.js"; @@ -10,9 +16,13 @@ import { serializeCreateCommentRequestBodyArgItemFieldTypeField } from "../manag import { deserializeCreateCommentRequestBodyArgItemFieldTypeField } from "../managers/comments.generated.js"; import { serializeUpdateCommentByIdRequestBodyArg } from "../managers/comments.generated.js"; import { deserializeUpdateCommentByIdRequestBodyArg } from "../managers/comments.generated.js"; +import { ByteStream } from "../utils.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { Comments } from "../schemas.generated.js"; +import { Comment } from "../schemas.generated.js"; import { CreateCommentRequestBodyArg } from "../managers/comments.generated.js"; import { CreateCommentRequestBodyArgItemField } from "../managers/comments.generated.js"; import { CreateCommentRequestBodyArgItemFieldTypeField } from "../managers/comments.generated.js"; diff --git a/src/test/commons.generated.ts b/src/test/commons.generated.ts index b56dc8ea..86c4f723 100644 --- a/src/test/commons.generated.ts +++ b/src/test/commons.generated.ts @@ -1,14 +1,24 @@ +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { File } from "../schemas.generated.js"; +import { ByteStream } from "../utils.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { decodeBase64 } from "../utils.js"; @@ -21,13 +31,13 @@ import { JwtConfig } from "../jwtAuth.js"; const jwtConfig: any = JwtConfig.fromConfigJsonString(decodeBase64(getEnvVar("JWT_CONFIG_BASE_64"))); const auth: any = new JwtAuth({ config: jwtConfig }); const client: any = new Client({ auth: auth }); -export async function uploadNewFile(): Promise { +export async function uploadNewFile(): Promise { const newFileName: any = "".concat(getUuid(), ".pdf") as string; const fileContentStream: any = generateByteStream(1048576); const uploadedFiles: any = await client.uploads.uploadFile({ attributes: { name: newFileName, parent: { id: "0" } satisfies UploadFileRequestBodyArgAttributesFieldParentField } satisfies UploadFileRequestBodyArgAttributesField, file: fileContentStream } satisfies UploadFileRequestBodyArg); return uploadedFiles.entries[0]; } -export async function createNewFolder(): Promise { +export async function createNewFolder(): Promise { const newFolderName: any = getUuid(); return await client.folders.createFolder({ name: newFolderName, parent: { id: "0" } satisfies CreateFolderRequestBodyArgParentField } satisfies CreateFolderRequestBodyArg); } diff --git a/src/test/downloads.generated.test.ts b/src/test/downloads.generated.test.ts index 665254fb..d13fdb87 100644 --- a/src/test/downloads.generated.test.ts +++ b/src/test/downloads.generated.test.ts @@ -1,10 +1,18 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { Buffer } from "../utils.js"; +import { ByteStream } from "../utils.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { File } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { getUuid } from "../utils.js"; diff --git a/src/test/emailAliases.generated.test.ts b/src/test/emailAliases.generated.test.ts index 4aa82438..59d8bee0 100644 --- a/src/test/emailAliases.generated.test.ts +++ b/src/test/emailAliases.generated.test.ts @@ -1,8 +1,17 @@ +import { serializeUser } from "../schemas.generated.js"; +import { deserializeUser } from "../schemas.generated.js"; import { serializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; import { deserializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; +import { serializeEmailAliases } from "../schemas.generated.js"; +import { deserializeEmailAliases } from "../schemas.generated.js"; +import { serializeEmailAlias } from "../schemas.generated.js"; +import { deserializeEmailAlias } from "../schemas.generated.js"; import { serializeCreateUserEmailAliasRequestBodyArg } from "../managers/emailAliases.generated.js"; import { deserializeCreateUserEmailAliasRequestBodyArg } from "../managers/emailAliases.generated.js"; +import { User } from "../schemas.generated.js"; import { CreateUserRequestBodyArg } from "../managers/users.generated.js"; +import { EmailAliases } from "../schemas.generated.js"; +import { EmailAlias } from "../schemas.generated.js"; import { CreateUserEmailAliasRequestBodyArg } from "../managers/emailAliases.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/fileMetadata.generated.test.ts b/src/test/fileMetadata.generated.test.ts index 8b429ed4..c02f14be 100644 --- a/src/test/fileMetadata.generated.test.ts +++ b/src/test/fileMetadata.generated.test.ts @@ -1,14 +1,26 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeMetadatas } from "../schemas.generated.js"; +import { deserializeMetadatas } from "../schemas.generated.js"; +import { serializeMetadata } from "../schemas.generated.js"; +import { deserializeMetadata } from "../schemas.generated.js"; +import { serializeMetadataFull } from "../schemas.generated.js"; +import { deserializeMetadataFull } from "../schemas.generated.js"; import { serializeUpdateFileMetadataByIdRequestBodyArg } from "../managers/fileMetadata.generated.js"; import { deserializeUpdateFileMetadataByIdRequestBodyArg } from "../managers/fileMetadata.generated.js"; import { serializeUpdateFileMetadataByIdRequestBodyArgOpField } from "../managers/fileMetadata.generated.js"; import { deserializeUpdateFileMetadataByIdRequestBodyArgOpField } from "../managers/fileMetadata.generated.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { Metadatas } from "../schemas.generated.js"; +import { Metadata } from "../schemas.generated.js"; +import { MetadataFull } from "../schemas.generated.js"; import { UpdateFileMetadataByIdRequestBodyArg } from "../managers/fileMetadata.generated.js"; import { UpdateFileMetadataByIdRequestBodyArgOpField } from "../managers/fileMetadata.generated.js"; import { decodeBase64 } from "../utils.js"; diff --git a/src/test/files.generated.test.ts b/src/test/files.generated.test.ts index 7bc8592e..a388dfb0 100644 --- a/src/test/files.generated.test.ts +++ b/src/test/files.generated.test.ts @@ -1,21 +1,34 @@ +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { serializeGetFileThumbnailByIdExtensionArg } from "../managers/files.generated.js"; import { deserializeGetFileThumbnailByIdExtensionArg } from "../managers/files.generated.js"; +import { serializeFileFull } from "../schemas.generated.js"; +import { deserializeFileFull } from "../schemas.generated.js"; +import { serializeTrashFile } from "../schemas.generated.js"; +import { deserializeTrashFile } from "../schemas.generated.js"; import { serializeUpdateFileByIdRequestBodyArg } from "../managers/files.generated.js"; import { deserializeUpdateFileByIdRequestBodyArg } from "../managers/files.generated.js"; import { serializeCopyFileRequestBodyArg } from "../managers/files.generated.js"; import { deserializeCopyFileRequestBodyArg } from "../managers/files.generated.js"; import { serializeCopyFileRequestBodyArgParentField } from "../managers/files.generated.js"; import { deserializeCopyFileRequestBodyArgParentField } from "../managers/files.generated.js"; +import { File } from "../schemas.generated.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { ByteStream } from "../utils.js"; import { GetFileThumbnailByIdExtensionArg } from "../managers/files.generated.js"; +import { FileFull } from "../schemas.generated.js"; import { GetFileByIdQueryParamsArg } from "../managers/files.generated.js"; import { GetFileByIdHeadersArg } from "../managers/files.generated.js"; +import { TrashFile } from "../schemas.generated.js"; import { UpdateFileByIdRequestBodyArg } from "../managers/files.generated.js"; import { CopyFileRequestBodyArg } from "../managers/files.generated.js"; import { CopyFileRequestBodyArgParentField } from "../managers/files.generated.js"; @@ -31,7 +44,7 @@ import { uploadNewFile } from "./commons.generated.js"; const jwtConfig: any = JwtConfig.fromConfigJsonString(decodeBase64(getEnvVar("JWT_CONFIG_BASE_64"))); const auth: any = new JwtAuth({ config: jwtConfig }); const client: any = new Client({ auth: auth }); -export async function uploadFile(fileName: any, fileStream: any): Promise { +export async function uploadFile(fileName: any, fileStream: any): Promise { const uploadedFiles: any = await client.uploads.uploadFile({ attributes: { name: fileName, parent: { id: "0" } satisfies UploadFileRequestBodyArgAttributesFieldParentField } satisfies UploadFileRequestBodyArgAttributesField, file: fileStream } satisfies UploadFileRequestBodyArg); return uploadedFiles.entries[0]; } diff --git a/src/test/folderLocks.generated.test.ts b/src/test/folderLocks.generated.test.ts index aaf07979..2c0fec15 100644 --- a/src/test/folderLocks.generated.test.ts +++ b/src/test/folderLocks.generated.test.ts @@ -1,16 +1,25 @@ +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { serializeFolderLocks } from "../schemas.generated.js"; +import { deserializeFolderLocks } from "../schemas.generated.js"; +import { serializeFolderLock } from "../schemas.generated.js"; +import { deserializeFolderLock } from "../schemas.generated.js"; import { serializeCreateFolderLockRequestBodyArg } from "../managers/folderLocks.generated.js"; import { deserializeCreateFolderLockRequestBodyArg } from "../managers/folderLocks.generated.js"; import { serializeCreateFolderLockRequestBodyArgFolderField } from "../managers/folderLocks.generated.js"; import { deserializeCreateFolderLockRequestBodyArgFolderField } from "../managers/folderLocks.generated.js"; import { serializeCreateFolderLockRequestBodyArgLockedOperationsField } from "../managers/folderLocks.generated.js"; import { deserializeCreateFolderLockRequestBodyArgLockedOperationsField } from "../managers/folderLocks.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { FolderLocks } from "../schemas.generated.js"; import { GetFolderLocksQueryParamsArg } from "../managers/folderLocks.generated.js"; +import { FolderLock } from "../schemas.generated.js"; import { CreateFolderLockRequestBodyArg } from "../managers/folderLocks.generated.js"; import { CreateFolderLockRequestBodyArgFolderField } from "../managers/folderLocks.generated.js"; import { CreateFolderLockRequestBodyArgLockedOperationsField } from "../managers/folderLocks.generated.js"; diff --git a/src/test/folders.generated.test.ts b/src/test/folders.generated.test.ts index 89779442..0934326f 100644 --- a/src/test/folders.generated.test.ts +++ b/src/test/folders.generated.test.ts @@ -1,3 +1,5 @@ +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; @@ -10,6 +12,9 @@ import { serializeCopyFolderRequestBodyArgParentField } from "../managers/folder import { deserializeCopyFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { serializeUpdateFolderByIdRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeUpdateFolderByIdRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { serializeItems } from "../schemas.generated.js"; +import { deserializeItems } from "../schemas.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { GetFolderByIdQueryParamsArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; @@ -17,6 +22,7 @@ import { UpdateFolderByIdRequestBodyArg } from "../managers/folders.generated.js import { CopyFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CopyFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { UpdateFolderByIdRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { Items } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { getUuid } from "../utils.js"; diff --git a/src/test/groups.generated.test.ts b/src/test/groups.generated.test.ts index d1e77813..bbf390eb 100644 --- a/src/test/groups.generated.test.ts +++ b/src/test/groups.generated.test.ts @@ -1,8 +1,17 @@ +import { serializeGroups } from "../schemas.generated.js"; +import { deserializeGroups } from "../schemas.generated.js"; +import { serializeGroup } from "../schemas.generated.js"; +import { deserializeGroup } from "../schemas.generated.js"; import { serializeCreateGroupRequestBodyArg } from "../managers/groups.generated.js"; import { deserializeCreateGroupRequestBodyArg } from "../managers/groups.generated.js"; +import { serializeGroupFull } from "../schemas.generated.js"; +import { deserializeGroupFull } from "../schemas.generated.js"; import { serializeUpdateGroupByIdRequestBodyArg } from "../managers/groups.generated.js"; import { deserializeUpdateGroupByIdRequestBodyArg } from "../managers/groups.generated.js"; +import { Groups } from "../schemas.generated.js"; +import { Group } from "../schemas.generated.js"; import { CreateGroupRequestBodyArg } from "../managers/groups.generated.js"; +import { GroupFull } from "../schemas.generated.js"; import { GetGroupByIdQueryParamsArg } from "../managers/groups.generated.js"; import { UpdateGroupByIdRequestBodyArg } from "../managers/groups.generated.js"; import { decodeBase64 } from "../utils.js"; diff --git a/src/test/memberships.generated.test.ts b/src/test/memberships.generated.test.ts index f78d2e20..08765de5 100644 --- a/src/test/memberships.generated.test.ts +++ b/src/test/memberships.generated.test.ts @@ -1,15 +1,27 @@ +import { serializeUser } from "../schemas.generated.js"; +import { deserializeUser } from "../schemas.generated.js"; import { serializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; import { deserializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; +import { serializeGroupMemberships } from "../schemas.generated.js"; +import { deserializeGroupMemberships } from "../schemas.generated.js"; +import { serializeGroup } from "../schemas.generated.js"; +import { deserializeGroup } from "../schemas.generated.js"; import { serializeCreateGroupRequestBodyArg } from "../managers/groups.generated.js"; import { deserializeCreateGroupRequestBodyArg } from "../managers/groups.generated.js"; +import { serializeGroupMembership } from "../schemas.generated.js"; +import { deserializeGroupMembership } from "../schemas.generated.js"; import { serializeCreateGroupMembershipRequestBodyArg } from "../managers/memberships.generated.js"; import { deserializeCreateGroupMembershipRequestBodyArg } from "../managers/memberships.generated.js"; import { serializeUpdateGroupMembershipByIdRequestBodyArg } from "../managers/memberships.generated.js"; import { deserializeUpdateGroupMembershipByIdRequestBodyArg } from "../managers/memberships.generated.js"; import { serializeUpdateGroupMembershipByIdRequestBodyArgRoleField } from "../managers/memberships.generated.js"; import { deserializeUpdateGroupMembershipByIdRequestBodyArgRoleField } from "../managers/memberships.generated.js"; +import { User } from "../schemas.generated.js"; import { CreateUserRequestBodyArg } from "../managers/users.generated.js"; +import { GroupMemberships } from "../schemas.generated.js"; +import { Group } from "../schemas.generated.js"; import { CreateGroupRequestBodyArg } from "../managers/groups.generated.js"; +import { GroupMembership } from "../schemas.generated.js"; import { CreateGroupMembershipRequestBodyArg } from "../managers/memberships.generated.js"; import { UpdateGroupMembershipByIdRequestBodyArg } from "../managers/memberships.generated.js"; import { UpdateGroupMembershipByIdRequestBodyArgRoleField } from "../managers/memberships.generated.js"; diff --git a/src/test/metadataTemplates.generated.test.ts b/src/test/metadataTemplates.generated.test.ts index 0a0906c6..0edcc613 100644 --- a/src/test/metadataTemplates.generated.test.ts +++ b/src/test/metadataTemplates.generated.test.ts @@ -1,11 +1,17 @@ +import { serializeMetadataTemplate } from "../schemas.generated.js"; +import { deserializeMetadataTemplate } from "../schemas.generated.js"; import { serializeCreateMetadataTemplateSchemaRequestBodyArg } from "../managers/metadataTemplates.generated.js"; import { deserializeCreateMetadataTemplateSchemaRequestBodyArg } from "../managers/metadataTemplates.generated.js"; import { serializeGetMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; import { deserializeGetMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; +import { serializeMetadataTemplates } from "../schemas.generated.js"; +import { deserializeMetadataTemplates } from "../schemas.generated.js"; import { serializeDeleteMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; import { deserializeDeleteMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; +import { MetadataTemplate } from "../schemas.generated.js"; import { CreateMetadataTemplateSchemaRequestBodyArg } from "../managers/metadataTemplates.generated.js"; import { GetMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; +import { MetadataTemplates } from "../schemas.generated.js"; import { DeleteMetadataTemplateSchemaScopeArg } from "../managers/metadataTemplates.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/recentItems.generated.test.ts b/src/test/recentItems.generated.test.ts index 22cad619..0abe0598 100644 --- a/src/test/recentItems.generated.test.ts +++ b/src/test/recentItems.generated.test.ts @@ -1,3 +1,6 @@ +import { serializeRecentItems } from "../schemas.generated.js"; +import { deserializeRecentItems } from "../schemas.generated.js"; +import { RecentItems } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { getUuid } from "../utils.js"; diff --git a/src/test/retentionPolicies.generated.test.ts b/src/test/retentionPolicies.generated.test.ts index 6e9152a7..6bdfa93c 100644 --- a/src/test/retentionPolicies.generated.test.ts +++ b/src/test/retentionPolicies.generated.test.ts @@ -1,3 +1,5 @@ +import { serializeRetentionPolicy } from "../schemas.generated.js"; +import { deserializeRetentionPolicy } from "../schemas.generated.js"; import { serializeCreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; import { deserializeCreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; import { serializeCreateRetentionPolicyRequestBodyArgPolicyTypeField } from "../managers/retentionPolicies.generated.js"; @@ -6,12 +8,16 @@ import { serializeCreateRetentionPolicyRequestBodyArgDispositionActionField } fr import { deserializeCreateRetentionPolicyRequestBodyArgDispositionActionField } from "../managers/retentionPolicies.generated.js"; import { serializeCreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; import { deserializeCreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; +import { serializeRetentionPolicies } from "../schemas.generated.js"; +import { deserializeRetentionPolicies } from "../schemas.generated.js"; import { serializeUpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; import { deserializeUpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; +import { RetentionPolicy } from "../schemas.generated.js"; import { CreateRetentionPolicyRequestBodyArg } from "../managers/retentionPolicies.generated.js"; import { CreateRetentionPolicyRequestBodyArgPolicyTypeField } from "../managers/retentionPolicies.generated.js"; import { CreateRetentionPolicyRequestBodyArgDispositionActionField } from "../managers/retentionPolicies.generated.js"; import { CreateRetentionPolicyRequestBodyArgRetentionTypeField } from "../managers/retentionPolicies.generated.js"; +import { RetentionPolicies } from "../schemas.generated.js"; import { UpdateRetentionPolicyByIdRequestBodyArg } from "../managers/retentionPolicies.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/signRequests.generated.test.ts b/src/test/signRequests.generated.test.ts index 948dc4c0..b5f25052 100644 --- a/src/test/signRequests.generated.test.ts +++ b/src/test/signRequests.generated.test.ts @@ -1,7 +1,15 @@ +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; +import { serializeSignRequest } from "../schemas.generated.js"; +import { deserializeSignRequest } from "../schemas.generated.js"; import { serializeFolderBaseTypeField } from "../schemas.generated.js"; import { deserializeFolderBaseTypeField } from "../schemas.generated.js"; import { serializeFileBaseTypeField } from "../schemas.generated.js"; import { deserializeFileBaseTypeField } from "../schemas.generated.js"; +import { serializeSignRequests } from "../schemas.generated.js"; +import { deserializeSignRequests } from "../schemas.generated.js"; import { serializeSignRequestCreateRequest } from "../schemas.generated.js"; import { deserializeSignRequestCreateRequest } from "../schemas.generated.js"; import { serializeSignRequestCreateSigner } from "../schemas.generated.js"; @@ -10,8 +18,12 @@ import { serializeFolderMini } from "../schemas.generated.js"; import { deserializeFolderMini } from "../schemas.generated.js"; import { serializeFileBase } from "../schemas.generated.js"; import { deserializeFileBase } from "../schemas.generated.js"; +import { File } from "../schemas.generated.js"; +import { FolderFull } from "../schemas.generated.js"; +import { SignRequest } from "../schemas.generated.js"; import { FolderBaseTypeField } from "../schemas.generated.js"; import { FileBaseTypeField } from "../schemas.generated.js"; +import { SignRequests } from "../schemas.generated.js"; import { DeleteFolderByIdQueryParamsArg } from "../managers/folders.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/tasks.generated.test.ts b/src/test/tasks.generated.test.ts index 64a3e4b8..5bd34d8b 100644 --- a/src/test/tasks.generated.test.ts +++ b/src/test/tasks.generated.test.ts @@ -1,7 +1,13 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { serializeTask } from "../schemas.generated.js"; +import { deserializeTask } from "../schemas.generated.js"; import { serializeCreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; import { deserializeCreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; import { serializeCreateTaskRequestBodyArgItemField } from "../managers/tasks.generated.js"; @@ -12,16 +18,22 @@ import { serializeCreateTaskRequestBodyArgActionField } from "../managers/tasks. import { deserializeCreateTaskRequestBodyArgActionField } from "../managers/tasks.generated.js"; import { serializeCreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; import { deserializeCreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; +import { serializeTasks } from "../schemas.generated.js"; +import { deserializeTasks } from "../schemas.generated.js"; import { serializeUpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; import { deserializeUpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { File } from "../schemas.generated.js"; +import { Task } from "../schemas.generated.js"; import { CreateTaskRequestBodyArg } from "../managers/tasks.generated.js"; import { CreateTaskRequestBodyArgItemField } from "../managers/tasks.generated.js"; import { CreateTaskRequestBodyArgItemFieldTypeField } from "../managers/tasks.generated.js"; import { CreateTaskRequestBodyArgActionField } from "../managers/tasks.generated.js"; import { CreateTaskRequestBodyArgCompletionRuleField } from "../managers/tasks.generated.js"; +import { Tasks } from "../schemas.generated.js"; import { UpdateTaskByIdRequestBodyArg } from "../managers/tasks.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/trashedFiles.generated.test.ts b/src/test/trashedFiles.generated.test.ts index 2e7df081..c30e1f13 100644 --- a/src/test/trashedFiles.generated.test.ts +++ b/src/test/trashedFiles.generated.test.ts @@ -1,10 +1,26 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; +import { serializeTrashFile } from "../schemas.generated.js"; +import { deserializeTrashFile } from "../schemas.generated.js"; +import { serializeFileFull } from "../schemas.generated.js"; +import { deserializeFileFull } from "../schemas.generated.js"; +import { serializeTrashFileRestored } from "../schemas.generated.js"; +import { deserializeTrashFileRestored } from "../schemas.generated.js"; +import { ByteStream } from "../utils.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { File } from "../schemas.generated.js"; +import { TrashFile } from "../schemas.generated.js"; +import { FileFull } from "../schemas.generated.js"; +import { TrashFileRestored } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { getUuid } from "../utils.js"; diff --git a/src/test/trashedFolders.generated.test.ts b/src/test/trashedFolders.generated.test.ts index 0d6b1f2a..52151f87 100644 --- a/src/test/trashedFolders.generated.test.ts +++ b/src/test/trashedFolders.generated.test.ts @@ -1,9 +1,18 @@ +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { serializeTrashFolder } from "../schemas.generated.js"; +import { deserializeTrashFolder } from "../schemas.generated.js"; +import { serializeTrashFolderRestored } from "../schemas.generated.js"; +import { deserializeTrashFolderRestored } from "../schemas.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { TrashFolder } from "../schemas.generated.js"; +import { TrashFolderRestored } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { getUuid } from "../utils.js"; diff --git a/src/test/uploads.generated.test.ts b/src/test/uploads.generated.test.ts index dccbad81..9917e74c 100644 --- a/src/test/uploads.generated.test.ts +++ b/src/test/uploads.generated.test.ts @@ -1,12 +1,19 @@ +import { serializeFiles } from "../schemas.generated.js"; +import { deserializeFiles } from "../schemas.generated.js"; import { serializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { serializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; import { deserializeUploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { serializeFile } from "../schemas.generated.js"; +import { deserializeFile } from "../schemas.generated.js"; import { serializeUploadFileVersionRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { deserializeUploadFileVersionRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; +import { ByteStream } from "../utils.js"; +import { Files } from "../schemas.generated.js"; import { UploadFileRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { UploadFileRequestBodyArgAttributesFieldParentField } from "../managers/uploads.generated.js"; +import { File } from "../schemas.generated.js"; import { UploadFileVersionRequestBodyArg } from "../managers/uploads.generated.js"; import { UploadFileVersionRequestBodyArgAttributesField } from "../managers/uploads.generated.js"; import { decodeBase64 } from "../utils.js"; diff --git a/src/test/users.generated.test.ts b/src/test/users.generated.test.ts index 3699185c..96024db2 100644 --- a/src/test/users.generated.test.ts +++ b/src/test/users.generated.test.ts @@ -1,7 +1,16 @@ +import { serializeUsers } from "../schemas.generated.js"; +import { deserializeUsers } from "../schemas.generated.js"; +import { serializeUserFull } from "../schemas.generated.js"; +import { deserializeUserFull } from "../schemas.generated.js"; +import { serializeUser } from "../schemas.generated.js"; +import { deserializeUser } from "../schemas.generated.js"; import { serializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; import { deserializeCreateUserRequestBodyArg } from "../managers/users.generated.js"; import { serializeUpdateUserByIdRequestBodyArg } from "../managers/users.generated.js"; import { deserializeUpdateUserByIdRequestBodyArg } from "../managers/users.generated.js"; +import { Users } from "../schemas.generated.js"; +import { UserFull } from "../schemas.generated.js"; +import { User } from "../schemas.generated.js"; import { CreateUserRequestBodyArg } from "../managers/users.generated.js"; import { UpdateUserByIdRequestBodyArg } from "../managers/users.generated.js"; import { decodeBase64 } from "../utils.js"; diff --git a/src/test/webhooks.generated.test.ts b/src/test/webhooks.generated.test.ts index 0141db6c..cdd56290 100644 --- a/src/test/webhooks.generated.test.ts +++ b/src/test/webhooks.generated.test.ts @@ -1,20 +1,29 @@ +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; import { serializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { serializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; import { deserializeCreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { serializeWebhook } from "../schemas.generated.js"; +import { deserializeWebhook } from "../schemas.generated.js"; import { serializeCreateWebhookRequestBodyArg } from "../managers/webhooks.generated.js"; import { deserializeCreateWebhookRequestBodyArg } from "../managers/webhooks.generated.js"; import { serializeCreateWebhookRequestBodyArgTargetField } from "../managers/webhooks.generated.js"; import { deserializeCreateWebhookRequestBodyArgTargetField } from "../managers/webhooks.generated.js"; import { serializeCreateWebhookRequestBodyArgTargetFieldTypeField } from "../managers/webhooks.generated.js"; import { deserializeCreateWebhookRequestBodyArgTargetFieldTypeField } from "../managers/webhooks.generated.js"; +import { serializeWebhooks } from "../schemas.generated.js"; +import { deserializeWebhooks } from "../schemas.generated.js"; import { serializeUpdateWebhookByIdRequestBodyArg } from "../managers/webhooks.generated.js"; import { deserializeUpdateWebhookByIdRequestBodyArg } from "../managers/webhooks.generated.js"; +import { FolderFull } from "../schemas.generated.js"; import { CreateFolderRequestBodyArg } from "../managers/folders.generated.js"; import { CreateFolderRequestBodyArgParentField } from "../managers/folders.generated.js"; +import { Webhook } from "../schemas.generated.js"; import { CreateWebhookRequestBodyArg } from "../managers/webhooks.generated.js"; import { CreateWebhookRequestBodyArgTargetField } from "../managers/webhooks.generated.js"; import { CreateWebhookRequestBodyArgTargetFieldTypeField } from "../managers/webhooks.generated.js"; +import { Webhooks } from "../schemas.generated.js"; import { UpdateWebhookByIdRequestBodyArg } from "../managers/webhooks.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; diff --git a/src/test/weblinks.generated.test.ts b/src/test/weblinks.generated.test.ts index 024ac432..01bd98d2 100644 --- a/src/test/weblinks.generated.test.ts +++ b/src/test/weblinks.generated.test.ts @@ -1,9 +1,15 @@ +import { serializeFolderFull } from "../schemas.generated.js"; +import { deserializeFolderFull } from "../schemas.generated.js"; +import { serializeWebLink } from "../schemas.generated.js"; +import { deserializeWebLink } from "../schemas.generated.js"; import { serializeCreateWebLinkRequestBodyArg } from "../managers/webLinks.generated.js"; import { deserializeCreateWebLinkRequestBodyArg } from "../managers/webLinks.generated.js"; import { serializeUpdateWebLinkByIdRequestBodyArg } from "../managers/webLinks.generated.js"; import { deserializeUpdateWebLinkByIdRequestBodyArg } from "../managers/webLinks.generated.js"; import { serializeUpdateWebLinkByIdRequestBodyArgSharedLinkField } from "../managers/webLinks.generated.js"; import { deserializeUpdateWebLinkByIdRequestBodyArgSharedLinkField } from "../managers/webLinks.generated.js"; +import { FolderFull } from "../schemas.generated.js"; +import { WebLink } from "../schemas.generated.js"; import { CreateWebLinkRequestBodyArg } from "../managers/webLinks.generated.js"; import { UpdateWebLinkByIdRequestBodyArg } from "../managers/webLinks.generated.js"; import { UpdateWebLinkByIdRequestBodyArgSharedLinkField } from "../managers/webLinks.generated.js"; diff --git a/src/utils.ts b/src/utils.ts index 90d835cf..3023d9e5 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -16,6 +16,13 @@ export function hexToBase64(data: string): string { export { Buffer, Readable as ByteStream }; +type AsyncIterator2 = AsyncIterator< + T, + TReturn, + TNext +>; +export type { AsyncIterator2 as AsyncIterator }; + export class Hash { #hash: crypto.Hash; @@ -60,6 +67,10 @@ export function bufferEquals(buffer1: Buffer, buffer2: Buffer): boolean { return Buffer.compare(buffer1, buffer2) === 0; } +export function bufferLength(buffer: Buffer): number { + return buffer.length; +} + export function decodeBase64ByteStream(data: string): Readable { return Readable.from(Buffer.from(data, 'base64')); } diff --git a/tsconfig.json b/tsconfig.json index 47c530a3..6bee0b58 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -11,11 +11,6 @@ "strict": true, "skipLibCheck": true }, - "include": [ - "src/**/*" - ], - "exclude": [ - "node_modules", - "src/__tests__" - ] -} \ No newline at end of file + "include": ["src/**/*"], + "exclude": ["node_modules", "src/__tests__"] +} diff --git a/tsconfig.test.json b/tsconfig.test.json index b2d38b68..e2a77fe6 100644 --- a/tsconfig.test.json +++ b/tsconfig.test.json @@ -1 +1,4 @@ -{"compilerOptions":{"types":["node","jest"]},"extends":"./tsconfig.json"} \ No newline at end of file +{ + "compilerOptions": { "types": ["node", "jest"] }, + "extends": "./tsconfig.json" +} From fe65f3b52de23f97ceabf0712155894ea7338a49 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Thu, 31 Aug 2023 08:52:49 -0700 Subject: [PATCH 7/8] generated with codegen at box/box-codegen@790e795 and spec at box/box-openapi@f01a34e --- src/schemas.generated.ts | 62 ++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 34 deletions(-) diff --git a/src/schemas.generated.ts b/src/schemas.generated.ts index bd93c6d1..75a4ead9 100644 --- a/src/schemas.generated.ts +++ b/src/schemas.generated.ts @@ -2809,37 +2809,19 @@ export type MetadataFieldFilterFloat = { export type MetadataFieldFilterMultiSelect = { readonly [key: string]: readonly string[]; }; +export interface MetadataFieldFilterFloatRangeMapValue { + readonly lt?: number; + readonly gt?: number; +} export type MetadataFieldFilterFloatRange = { - readonly [key: string]: { - /** - * Specifies the (inclusive) upper bound for the metadata field - * value. The value of a field must be lower than (`lt`) or - * equal to this value for the search query to match this - * template. */ - readonly lt?: number; - /** - * Specifies the (inclusive) lower bound for the metadata field - * value. The value of a field must be greater than (`gt`) or - * equal to this value for the search query to match this - * template. */ - readonly gt?: number; - }; + readonly [key: string]: MetadataFieldFilterFloatRangeMapValue; }; +export interface MetadataFieldFilterDateRangeMapValue { + readonly lt?: string; + readonly gt?: string; +} export type MetadataFieldFilterDateRange = { - readonly [key: string]: { - /** - * Specifies the (inclusive) upper bound for the metadata field - * value. The value of a field must be lower than (`lt`) or - * equal to this value for the search query to match this - * template. */ - readonly lt?: string; - /** - * Specifies the (inclusive) lower bound for the metadata field - * value. The value of a field must be greater than (`gt`) or - * equal to this value for the search query to match this - * template. */ - readonly gt?: string; - }; + readonly [key: string]: MetadataFieldFilterDateRangeMapValue; }; export function serializePostOAuth2TokenGrantTypeField(val: PostOAuth2TokenGrantTypeField): Json { return val; @@ -11141,26 +11123,38 @@ export function serializeMetadataFieldFilterMultiSelect(val: MetadataFieldFilter export function deserializeMetadataFieldFilterMultiSelect(val: any): MetadataFieldFilterMultiSelect { return val; } +export function serializeMetadataFieldFilterFloatRangeMapValue(val: MetadataFieldFilterFloatRangeMapValue): Json { + return { ["lt"]: val.lt == void 0 ? void 0 : val.lt, ["gt"]: val.gt == void 0 ? void 0 : val.gt }; +} +export function deserializeMetadataFieldFilterFloatRangeMapValue(val: any): MetadataFieldFilterFloatRangeMapValue { + const lt: undefined | number = val.lt == void 0 ? void 0 : val.lt; + const gt: undefined | number = val.gt == void 0 ? void 0 : val.gt; + return { lt: lt, gt: gt } satisfies MetadataFieldFilterFloatRangeMapValue; +} export function serializeMetadataFieldFilterFloatRange(val: MetadataFieldFilterFloatRange): Json { return Object.fromEntries(Object.entries(val).map(([k, v]: [ string, any - ]) => [k, function (v: any): any { - return { ["lt"]: v.lt == void 0 ? void 0 : v.lt, ["gt"]: v.gt == void 0 ? void 0 : v.gt }; - }(v)])) as { + ]) => [k, serializeMetadataFieldFilterFloatRangeMapValue(v)])) as { readonly [key: string]: any; }; } export function deserializeMetadataFieldFilterFloatRange(val: any): MetadataFieldFilterFloatRange { return val; } +export function serializeMetadataFieldFilterDateRangeMapValue(val: MetadataFieldFilterDateRangeMapValue): Json { + return { ["lt"]: val.lt == void 0 ? void 0 : val.lt, ["gt"]: val.gt == void 0 ? void 0 : val.gt }; +} +export function deserializeMetadataFieldFilterDateRangeMapValue(val: any): MetadataFieldFilterDateRangeMapValue { + const lt: undefined | string = val.lt == void 0 ? void 0 : val.lt; + const gt: undefined | string = val.gt == void 0 ? void 0 : val.gt; + return { lt: lt, gt: gt } satisfies MetadataFieldFilterDateRangeMapValue; +} export function serializeMetadataFieldFilterDateRange(val: MetadataFieldFilterDateRange): Json { return Object.fromEntries(Object.entries(val).map(([k, v]: [ string, any - ]) => [k, function (v: any): any { - return { ["lt"]: v.lt == void 0 ? void 0 : v.lt, ["gt"]: v.gt == void 0 ? void 0 : v.gt }; - }(v)])) as { + ]) => [k, serializeMetadataFieldFilterDateRangeMapValue(v)])) as { readonly [key: string]: any; }; } From 239e103a7d5151edc303e2732135c810a39802f9 Mon Sep 17 00:00:00 2001 From: box-sdk-build Date: Fri, 1 Sep 2023 01:43:00 -0700 Subject: [PATCH 8/8] generated with codegen at box/box-codegen@5aebe76 and spec at box/box-openapi@f01a34e --- src/auth.ts | 7 +++++-- src/authSchemas.ts | 25 ------------------------- src/ccgAuth.ts | 11 +++++------ src/developerTokenAuth.ts | 5 +++-- src/fetch.ts | 6 +++--- src/jwtAuth.ts | 11 +++++------ src/oauth.ts | 30 ++++++++++++++---------------- src/test/auth.generated.test.ts | 3 ++- 8 files changed, 37 insertions(+), 61 deletions(-) diff --git a/src/auth.ts b/src/auth.ts index f4f3cb12..698cad32 100644 --- a/src/auth.ts +++ b/src/auth.ts @@ -1,6 +1,9 @@ import { NetworkSession } from './network'; +import { AccessToken } from './schemas.generated.js'; export interface Authentication { - retrieveToken: (networkSession?: NetworkSession) => Promise; - refreshToken: (networkSession?: NetworkSession) => Promise; + retrieveToken: (networkSession?: NetworkSession) => Promise; + refreshToken: ( + networkSession?: NetworkSession + ) => Promise; } diff --git a/src/authSchemas.ts b/src/authSchemas.ts index 6e850723..0813c110 100644 --- a/src/authSchemas.ts +++ b/src/authSchemas.ts @@ -107,28 +107,3 @@ export type FileScope = | 'item_preview' | 'item_rename' | 'item_share'; - -export interface AccessToken { - /** - * The requested access token. */ - readonly access_token?: string; - /** - * The time in seconds in seconds by which this token will expire. */ - readonly expires_in?: number; - /** - * The type of access token returned. */ - readonly token_type?: 'bearer'; - /** - * The permissions that this access token permits, - * providing a list of resources (files, folders, etc) - * and the scopes permitted for each of those resources. */ - readonly restricted_to?: FileScope[]; - /** - * The refresh token for this access token, which can be used - * to request a new access token when the current one expires. */ - readonly refresh_token?: string; - /** - * The type of downscoped access token returned. This is only - * returned if an access token has been downscoped. */ - readonly issued_token_type?: 'urn:ietf:params:oauth:token-type:access_token'; -} diff --git a/src/ccgAuth.ts b/src/ccgAuth.ts index 61255fc9..c8fcf49f 100644 --- a/src/ccgAuth.ts +++ b/src/ccgAuth.ts @@ -1,12 +1,12 @@ -import { fetch, FetchOptions, FetchResponse } from './fetch.js'; +import { Authentication } from './auth'; import { - AccessToken, TokenRequest, TokenRequestBoxSubjectType, TokenRequestGrantType, } from './authSchemas'; -import { Authentication } from './auth'; +import { FetchOptions, FetchResponse, fetch } from './fetch.js'; import { NetworkSession } from './network'; +import { AccessToken, deserializeAccessToken } from './schemas.generated.js'; export type CcgConfig = { clientId: string; @@ -17,7 +17,7 @@ export type CcgConfig = { export class CcgAuth implements Authentication { config: CcgConfig; - token?: string; + token?: AccessToken; subjectId: string; subjectType: string; @@ -61,8 +61,7 @@ export class CcgAuth implements Authentication { networkSession: networkSession, } as FetchOptions)) as FetchResponse; - const tokenResponse = JSON.parse(response.text) as AccessToken; - this.token = tokenResponse.access_token; + this.token = deserializeAccessToken(JSON.parse(response.text)); return this.token; } diff --git a/src/developerTokenAuth.ts b/src/developerTokenAuth.ts index e3487c93..b156a475 100644 --- a/src/developerTokenAuth.ts +++ b/src/developerTokenAuth.ts @@ -1,11 +1,12 @@ import { Authentication } from './auth'; +import { AccessToken } from './schemas.generated.js'; import { NetworkSession } from './network'; export class DeveloperTokenAuth implements Authentication { - token: string; + token: AccessToken; constructor({ token }: { token: string }) { - this.token = token; + this.token = { accessToken: token } satisfies AccessToken; } async retrieveToken(networkSession?: NetworkSession) { diff --git a/src/fetch.ts b/src/fetch.ts index 8d670d69..df76d5b2 100644 --- a/src/fetch.ts +++ b/src/fetch.ts @@ -117,9 +117,9 @@ async function createFetchOptions(options: FetchOptions): Promise { 'Content-Type': contentType, ...headers, ...(options.auth && { - Authorization: `Bearer ${await options.auth.retrieveToken( - options.networkSession - )}`, + Authorization: `Bearer ${ + (await options.auth.retrieveToken(options.networkSession)).accessToken + }`, }), 'User-Agent': userAgentHeader, 'X-Box-UA': xBoxUaHeader, diff --git a/src/jwtAuth.ts b/src/jwtAuth.ts index 1677f088..0e10966b 100644 --- a/src/jwtAuth.ts +++ b/src/jwtAuth.ts @@ -1,9 +1,9 @@ import { - AccessToken, TokenRequest, TokenRequestBoxSubjectType, TokenRequestGrantType, } from './authSchemas.js'; +import { AccessToken, deserializeAccessToken } from './schemas.generated.js'; import { readFileSync } from 'fs'; import jwt from 'jsonwebtoken'; import { v4 as uuid } from 'uuid'; @@ -131,7 +131,7 @@ export class JwtConfig { */ export class JwtAuth implements Authentication { config: JwtConfig; - token?: string; + token?: AccessToken; subjectId: string; subjectType: string; @@ -151,7 +151,7 @@ export class JwtAuth implements Authentication { * Get the access token for the app user. If the token is not cached or is expired, a new one will be fetched. * @returns {Promise} A promise resolving to the access token. */ - async retrieveToken(networkSession?: NetworkSession): Promise { + async retrieveToken(networkSession?: NetworkSession): Promise { if (!this.token) { await this.refreshToken(networkSession); } @@ -164,7 +164,7 @@ export class JwtAuth implements Authentication { */ async refreshToken( networkSession?: NetworkSession - ): Promise { + ): Promise { const expInSec = Math.floor(Date.now() / 1000) + 30; const claims = { exp: expInSec, @@ -202,8 +202,7 @@ export class JwtAuth implements Authentication { }; const response = (await fetch(BOX_JWT_AUDIENCE, params)) as FetchResponse; - const tokenResponse = JSON.parse(response.text) as AccessToken; - this.token = tokenResponse.access_token; + this.token = deserializeAccessToken(JSON.parse(response.text)); return this.token; } diff --git a/src/oauth.ts b/src/oauth.ts index 6671cc36..c5337212 100644 --- a/src/oauth.ts +++ b/src/oauth.ts @@ -1,11 +1,8 @@ -import { - AccessToken, - TokenRequest, - TokenRequestGrantType, -} from './authSchemas.js'; import { Authentication } from './auth.js'; +import { TokenRequest, TokenRequestGrantType } from './authSchemas.js'; +import { FetchOptions, FetchResponse, fetch } from './fetch.js'; import { NetworkSession } from './network.js'; -import { fetch, FetchOptions, FetchResponse } from './fetch.js'; +import { AccessToken, deserializeAccessToken } from './schemas.generated.js'; const BOX_OAUTH2_AUTH_URL = 'https://account.box.com/api/oauth2/authorize'; const BOX_OAUTH2_TOKEN_URL = 'https://api.box.com/oauth2/token'; @@ -126,12 +123,12 @@ export class OAuth implements Authentication { params )) as FetchResponse; - const tokenResponse = JSON.parse(response.text) as AccessToken; + const tokenResponse = JSON.parse(response.text); if (!isValidOAuthTokenResponse(tokenResponse)) { throw new Error('Invalid token response'); } - this.token = tokenResponse; - return this.token!.access_token!; + this.token = deserializeAccessToken(tokenResponse); + return this.token!.accessToken!; } /** @@ -139,13 +136,13 @@ export class OAuth implements Authentication { * @param networkSession An object to keep network session state * @returns {Promise} A promise resolving to the access token. */ - async retrieveToken(networkSession?: NetworkSession): Promise { + async retrieveToken(networkSession?: NetworkSession): Promise { if (!this.token) { throw Error( 'Access and refresh tokens not available. Authenticate before making any API call first.' ); } - return this.token.access_token as string; + return this.token; } /** @@ -154,13 +151,14 @@ export class OAuth implements Authentication { * @returns {Promise} A promise resolving to the access token. */ async refreshToken( - networkSession?: NetworkSession - ): Promise { + networkSession?: NetworkSession, + refreshToken?: string + ): Promise { const requestBody: TokenRequest = { grant_type: BOX_REFRESH_TOKEN_GRANT_TYPE, client_id: this.config.clientId, client_secret: this.config.clientSecret, - refresh_token: this.token!.refresh_token, + refresh_token: refreshToken ?? this.token!.refreshToken, }; const params: FetchOptions = { method: 'POST', @@ -176,7 +174,7 @@ export class OAuth implements Authentication { BOX_OAUTH2_TOKEN_URL, params )) as FetchResponse; - this.token = JSON.parse(response.text) as AccessToken; - return this.token.access_token; + this.token = deserializeAccessToken(JSON.parse(response.text)); + return this.token; } } diff --git a/src/test/auth.generated.test.ts b/src/test/auth.generated.test.ts index 6880c7cc..d27213c8 100644 --- a/src/test/auth.generated.test.ts +++ b/src/test/auth.generated.test.ts @@ -1,6 +1,7 @@ import { serializeUserFull } from "../schemas.generated.js"; import { deserializeUserFull } from "../schemas.generated.js"; import { GetUserMeQueryParamsArg } from "../managers/users.generated.js"; +import { AccessToken } from "../schemas.generated.js"; import { decodeBase64 } from "../utils.js"; import { getEnvVar } from "../utils.js"; import { Client } from "../client.generated.js"; @@ -58,7 +59,7 @@ test("test_developer_token_auth", async function test_developer_token_auth(): Pr const auth: any = new JwtAuth({ config: jwtConfig }); auth.asUser(userId) const token: any = await auth.retrieveToken(); - const devAuth: any = new DeveloperTokenAuth({ token: token }); + const devAuth: any = new DeveloperTokenAuth({ token: token.accessToken }); const client: any = new Client({ auth: devAuth }); const currentUser: any = await client.users.getUserMe(); if (!(currentUser.id == userId)) {