Skip to content

Commit

Permalink
docs: Improve code samples in docs (box/box-codegen#661) (#214)
Browse files Browse the repository at this point in the history
Co-authored-by: box-sdk-build <[email protected]>
  • Loading branch information
box-sdk-build and box-sdk-build authored Feb 10, 2025
1 parent 7e1b743 commit 677372e
Show file tree
Hide file tree
Showing 26 changed files with 39 additions and 39 deletions.
2 changes: 1 addition & 1 deletion .codegen.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{ "engineHash": "cb61d82", "specHash": "59747aa", "version": "0.4.0" }
{ "engineHash": "2c730de", "specHash": "59747aa", "version": "0.4.0" }
6 changes: 3 additions & 3 deletions docs/ai.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ See the endpoint docs at

<!-- sample post_ai_ask -->
```
client.getAi().createAiAsk(new AiAsk(AiAskModeField.MULTIPLE_ITEM_QA, "Which direction sun rises?", Arrays.asList(new AiItemAsk.AiItemAskBuilder(fileToAsk1.getId(), AiItemAskTypeField.FILE).content("Earth goes around the sun").build(), new AiItemAsk.AiItemAskBuilder(fileToAsk2.getId(), AiItemAskTypeField.FILE).content("Sun rises in the East in the morning").build())))
client.getAi().createAiAsk(new AiAsk(AiAskModeField.SINGLE_ITEM_QA, "which direction sun rises", Arrays.asList(new AiItemAsk.AiItemAskBuilder(fileToAsk.getId(), AiItemAskTypeField.FILE).content("Sun rises in the East").build())))
```

### Arguments
Expand Down Expand Up @@ -76,7 +76,7 @@ See the endpoint docs at

<!-- sample get_ai_agent_default -->
```
client.getAi().getAiAgentDefaultConfig(new GetAiAgentDefaultConfigQueryParams.GetAiAgentDefaultConfigQueryParamsBuilder(GetAiAgentDefaultConfigQueryParamsModeField.TEXT_GEN).language("en-US").build())
client.getAi().getAiAgentDefaultConfig(new GetAiAgentDefaultConfigQueryParams.GetAiAgentDefaultConfigQueryParamsBuilder(GetAiAgentDefaultConfigQueryParamsModeField.ASK).language("en-US").build())
```

### Arguments
Expand Down Expand Up @@ -146,7 +146,7 @@ See the endpoint docs at

<!-- sample post_ai_extract_structured -->
```
client.getAi().createAiExtractStructured(new AiExtractStructured.AiExtractStructuredBuilder(Arrays.asList(new AiItemBase(file.getId()))).metadataTemplate(new AiExtractStructuredMetadataTemplateField.AiExtractStructuredMetadataTemplateFieldBuilder().templateKey(templateKey).scope("enterprise").build()).build())
client.getAi().createAiExtractStructured(new AiExtractStructured.AiExtractStructuredBuilder(Arrays.asList(new AiItemBase(file.getId()))).fields(Arrays.asList(new AiExtractStructuredFieldsField.AiExtractStructuredFieldsFieldBuilder("firstName").description("Person first name").displayName("First name").prompt("What is the your first name?").type("string").build(), new AiExtractStructuredFieldsField.AiExtractStructuredFieldsFieldBuilder("lastName").description("Person last name").displayName("Last name").prompt("What is the your last name?").type("string").build(), new AiExtractStructuredFieldsField.AiExtractStructuredFieldsFieldBuilder("dateOfBirth").description("Person date of birth").displayName("Birth date").prompt("What is the date of your birth?").type("date").build(), new AiExtractStructuredFieldsField.AiExtractStructuredFieldsFieldBuilder("age").description("Person age").displayName("Age").prompt("How old are you?").type("float").build(), new AiExtractStructuredFieldsField.AiExtractStructuredFieldsFieldBuilder("hobby").description("Person hobby").displayName("Hobby").prompt("What is your hobby?").type("multiSelect").options(Arrays.asList(new AiExtractStructuredFieldsOptionsField("guitar"), new AiExtractStructuredFieldsOptionsField("books"))).build())).build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/collaborationallowlistentries.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ See the endpoint docs at

<!-- sample get_collaboration_whitelist_entries_id -->
```
client.getCollaborationAllowlistEntries().getCollaborationWhitelistEntryById(entry.getId())
client.getCollaborationAllowlistEntries().getCollaborationWhitelistEntryById(newEntry.getId())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/collaborationallowlistexempttargets.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ See the endpoint docs at

<!-- sample get_collaboration_whitelist_exempt_targets_id -->
```
client.getCollaborationAllowlistExemptTargets().getCollaborationWhitelistExemptTargetById(exemptTarget.getId())
client.getCollaborationAllowlistExemptTargets().getCollaborationWhitelistExemptTargetById(newExemptTarget.getId())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ See the endpoint docs at

<!-- sample post_comments -->
```
client.getComments().createComment(new CreateCommentRequestBody(message, new CreateCommentRequestBodyItemField(newComment.getId(), CreateCommentRequestBodyItemTypeField.COMMENT)))
client.getComments().createComment(new CreateCommentRequestBody(message, new CreateCommentRequestBodyItemField(fileId, CreateCommentRequestBodyItemTypeField.FILE)))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/devicepinners.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ See the endpoint docs at

<!-- sample get_enterprises_id_device_pinners -->
```
client.getDevicePinners().getEnterpriseDevicePinners(enterpriseId, new GetEnterpriseDevicePinnersQueryParams.GetEnterpriseDevicePinnersQueryParamsBuilder().direction(GetEnterpriseDevicePinnersQueryParamsDirectionField.DESC).build())
client.getDevicePinners().getEnterpriseDevicePinners(enterpriseId)
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/docgentemplate.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ See the endpoint docs at

<!-- sample post_docgen_templates_v2025.0 -->
```
client.getDocgenTemplate().createDocgenTemplateV2025R0(new DocGenTemplateCreateRequestV2025R0(new FileReferenceV2025R0(uploadedFile.getId())))
client.getDocgenTemplate().createDocgenTemplateV2025R0(new DocGenTemplateCreateRequestV2025R0(new FileReferenceV2025R0(file.getId())))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/filerequests.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ See the endpoint docs at

<!-- sample get_file_requests_id -->
```
client.getFileRequests().getFileRequestById(updatedFileRequest.getId())
client.getFileRequests().getFileRequestById(fileRequestId)
```

### Arguments
Expand Down
6 changes: 3 additions & 3 deletions docs/files.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ See the endpoint docs at

<!-- sample get_files_id -->
```
client.getFiles().getFileById(fileId, new GetFileByIdQueryParams.GetFileByIdQueryParamsBuilder().fields(Arrays.asList("is_associated_with_app_item")).build())
client.getFiles().getFileById(uploadedFile.getId(), new GetFileByIdQueryParams.GetFileByIdQueryParamsBuilder().fields(Arrays.asList("is_externally_owned", "has_collaborations")).build())
```

### Arguments
Expand Down Expand Up @@ -55,7 +55,7 @@ See the endpoint docs at

<!-- sample put_files_id -->
```
downscopedClient.getFiles().updateFileById(file.getId(), new UpdateFileByIdRequestBody.UpdateFileByIdRequestBodyBuilder().name(getUuid()).build())
client.getFiles().updateFileById(fileToUpdate.getId(), new UpdateFileByIdRequestBody.UpdateFileByIdRequestBodyBuilder().name(updatedName).description("Updated description").build())
```

### Arguments
Expand Down Expand Up @@ -96,7 +96,7 @@ See the endpoint docs at

<!-- sample delete_files_id -->
```
parentClient.getFiles().deleteFileById(file.getId())
client.getFiles().deleteFileById(thumbnailFile.getId())
```

### Arguments
Expand Down
8 changes: 4 additions & 4 deletions docs/folders.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ See the endpoint docs at

<!-- sample get_folders_id -->
```
client.getFolders().getFolderById(folderId, new GetFolderByIdQueryParams.GetFolderByIdQueryParamsBuilder().fields(Arrays.asList("is_associated_with_app_item")).build())
client.getFolders().getFolderById("0")
```

### Arguments
Expand Down Expand Up @@ -70,7 +70,7 @@ See the endpoint docs at

<!-- sample put_folders_id -->
```
downscopedClient.getFolders().updateFolderById(folder.getId(), new UpdateFolderByIdRequestBody.UpdateFolderByIdRequestBodyBuilder().name(getUuid()).build())
client.getFolders().updateFolderById(folderToUpdate.getId(), new UpdateFolderByIdRequestBody.UpdateFolderByIdRequestBodyBuilder().name(updatedName).description("Updated description").build())
```

### Arguments
Expand Down Expand Up @@ -113,7 +113,7 @@ See the endpoint docs at

<!-- sample delete_folders_id -->
```
parentClient.getFolders().deleteFolderById(folder.getId())
client.getFolders().deleteFolderById(newFolder.getId())
```

### Arguments
Expand Down Expand Up @@ -180,7 +180,7 @@ See the endpoint docs at

<!-- sample post_folders -->
```
parentClient.getFolders().createFolder(new CreateFolderRequestBody(getUuid(), new CreateFolderRequestBodyParentField("0")))
client.getFolders().createFolder(new CreateFolderRequestBody(newFolderName, new CreateFolderRequestBodyParentField("0")))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/groups.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ See the endpoint docs at

<!-- sample get_groups_id -->
```
client.getGroups().getGroupById(group.getId())
client.getGroups().getGroupById(group.getId(), new GetGroupByIdQueryParams.GetGroupByIdQueryParamsBuilder().fields(Arrays.asList("id", "name", "description", "group_type")).build())
```

### Arguments
Expand Down
4 changes: 2 additions & 2 deletions docs/legalholdpolicies.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ See the endpoint docs at

<!-- sample post_legal_hold_policies -->
```
client.getLegalHoldPolicies().createLegalHoldPolicy(new CreateLegalHoldPolicyRequestBody.CreateLegalHoldPolicyRequestBodyBuilder(legalHoldPolicyName).description(legalHoldDescription).filterStartedAt(filterStartedAt).filterEndedAt(filterEndedAt).isOngoing(false).build())
client.getLegalHoldPolicies().createLegalHoldPolicy(new CreateLegalHoldPolicyRequestBody.CreateLegalHoldPolicyRequestBodyBuilder(legalHoldPolicyName).description(legalHoldDescription).isOngoing(true).build())
```

### Arguments
Expand Down Expand Up @@ -140,7 +140,7 @@ See the endpoint docs at

<!-- sample delete_legal_hold_policies_id -->
```
client.getLegalHoldPolicies().deleteLegalHoldPolicyById(legalHoldPolicy.getId())
client.getLegalHoldPolicies().deleteLegalHoldPolicyById(legalHoldPolicyId)
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/metadatatemplates.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ See the endpoint docs at

<!-- sample post_metadata_templates_schema -->
```
client.getMetadataTemplates().createMetadataTemplate(new CreateMetadataTemplateRequestBody.CreateMetadataTemplateRequestBodyBuilder("enterprise", templateKey).templateKey(templateKey).fields(Arrays.asList(new CreateMetadataTemplateRequestBodyFieldsField.CreateMetadataTemplateRequestBodyFieldsFieldBuilder(CreateMetadataTemplateRequestBodyFieldsTypeField.STRING, "firstName", "First name").description("Person first name").build(), new CreateMetadataTemplateRequestBodyFieldsField.CreateMetadataTemplateRequestBodyFieldsFieldBuilder(CreateMetadataTemplateRequestBodyFieldsTypeField.STRING, "lastName", "Last name").description("Person last name").build(), new CreateMetadataTemplateRequestBodyFieldsField.CreateMetadataTemplateRequestBodyFieldsFieldBuilder(CreateMetadataTemplateRequestBodyFieldsTypeField.DATE, "dateOfBirth", "Birth date").description("Person date of birth").build(), new CreateMetadataTemplateRequestBodyFieldsField.CreateMetadataTemplateRequestBodyFieldsFieldBuilder(CreateMetadataTemplateRequestBodyFieldsTypeField.FLOAT, "age", "Age").description("Person age").build(), new CreateMetadataTemplateRequestBodyFieldsField.CreateMetadataTemplateRequestBodyFieldsFieldBuilder(CreateMetadataTemplateRequestBodyFieldsTypeField.MULTISELECT, "hobby", "Hobby").description("Person hobby").options(Arrays.asList(new CreateMetadataTemplateRequestBodyFieldsOptionsField("guitar"), new CreateMetadataTemplateRequestBodyFieldsOptionsField("books"))).build())).build())
client.getMetadataTemplates().createMetadataTemplate(new CreateMetadataTemplateRequestBody.CreateMetadataTemplateRequestBodyBuilder("enterprise", templateKey).templateKey(templateKey).fields(Arrays.asList(new CreateMetadataTemplateRequestBodyFieldsField(CreateMetadataTemplateRequestBodyFieldsTypeField.STRING, "testName", "testName"))).build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/retentionpolicies.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ See the endpoint docs at

<!-- sample post_retention_policies -->
```
client.getRetentionPolicies().createRetentionPolicy(new CreateRetentionPolicyRequestBody.CreateRetentionPolicyRequestBodyBuilder(getUuid(), CreateRetentionPolicyRequestBodyPolicyTypeField.FINITE, CreateRetentionPolicyRequestBodyDispositionActionField.REMOVE_RETENTION).description(description).retentionLength("1").retentionType(CreateRetentionPolicyRequestBodyRetentionTypeField.MODIFIABLE).canOwnerExtendRetention(false).build())
client.getRetentionPolicies().createRetentionPolicy(new CreateRetentionPolicyRequestBody.CreateRetentionPolicyRequestBodyBuilder(retentionPolicyName, CreateRetentionPolicyRequestBodyPolicyTypeField.FINITE, CreateRetentionPolicyRequestBodyDispositionActionField.REMOVE_RETENTION).description(retentionDescription).retentionLength("1").retentionType(CreateRetentionPolicyRequestBodyRetentionTypeField.MODIFIABLE).canOwnerExtendRetention(true).areOwnersNotified(true).build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/sharedlinksfiles.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ See the endpoint docs at

<!-- sample get_shared_items -->
```
userClient.getSharedLinksFiles().findFileForSharedLink(new FindFileForSharedLinkQueryParams(), new FindFileForSharedLinkHeaders(String.join("", "shared_link=", fileFromApi.getSharedLink().getUrl(), "&shared_link_password=incorrectPassword")))
userClient.getSharedLinksFiles().findFileForSharedLink(new FindFileForSharedLinkQueryParams(), new FindFileForSharedLinkHeaders(String.join("", "shared_link=", fileFromApi.getSharedLink().getUrl(), "&shared_link_password=Secret123@")))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/sharedlinksfolders.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ See the endpoint docs at

<!-- sample get_shared_items#folders -->
```
userClient.getSharedLinksFolders().findFolderForSharedLink(new FindFolderForSharedLinkQueryParams(), new FindFolderForSharedLinkHeaders(String.join("", "shared_link=", folderFromApi.getSharedLink().getUrl(), "&shared_link_password=incorrectPassword")))
userClient.getSharedLinksFolders().findFolderForSharedLink(new FindFolderForSharedLinkQueryParams(), new FindFolderForSharedLinkHeaders(String.join("", "shared_link=", folderFromApi.getSharedLink().getUrl(), "&shared_link_password=Secret123@")))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/sharedlinksweblinks.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ See the endpoint docs at

<!-- sample get_shared_items#web_links -->
```
userClient.getSharedLinksWebLinks().findWebLinkForSharedLink(new FindWebLinkForSharedLinkQueryParams(), new FindWebLinkForSharedLinkHeaders(String.join("", "shared_link=", webLinkFromApi.getSharedLink().getUrl(), "&shared_link_password=incorrectPassword")))
userClient.getSharedLinksWebLinks().findWebLinkForSharedLink(new FindWebLinkForSharedLinkQueryParams(), new FindWebLinkForSharedLinkHeaders(String.join("", "shared_link=", webLinkFromApi.getSharedLink().getUrl(), "&shared_link_password=Secret123@")))
```

### Arguments
Expand Down
4 changes: 2 additions & 2 deletions docs/shieldinformationbarriersegments.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ See the endpoint docs at

<!-- sample delete_shield_information_barrier_segments_id -->
```
client.getShieldInformationBarrierSegments().deleteShieldInformationBarrierSegmentById(segment.getId())
client.getShieldInformationBarrierSegments().deleteShieldInformationBarrierSegmentById(segmentId)
```

### Arguments
Expand Down Expand Up @@ -138,7 +138,7 @@ See the endpoint docs at

<!-- sample post_shield_information_barrier_segments -->
```
client.getShieldInformationBarrierSegments().createShieldInformationBarrierSegment(new CreateShieldInformationBarrierSegmentRequestBody(new ShieldInformationBarrierBase.ShieldInformationBarrierBaseBuilder().id(barrierId).type(ShieldInformationBarrierBaseTypeField.SHIELD_INFORMATION_BARRIER).build(), segmentName))
client.getShieldInformationBarrierSegments().createShieldInformationBarrierSegment(new CreateShieldInformationBarrierSegmentRequestBody.CreateShieldInformationBarrierSegmentRequestBodyBuilder(new ShieldInformationBarrierBase.ShieldInformationBarrierBaseBuilder().id(barrierId).type(ShieldInformationBarrierBaseTypeField.SHIELD_INFORMATION_BARRIER).build(), segmentName).description(segmentDescription).build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/signrequests.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ See the endpoint docs at

<!-- sample post_sign_requests -->
```
client.getSignRequests().createSignRequest(new SignRequestCreateRequest.SignRequestCreateRequestBuilder(Arrays.asList(new SignRequestCreateSigner.SignRequestCreateSignerBuilder().email(signer1Email).signerGroupId("user").build(), new SignRequestCreateSigner.SignRequestCreateSignerBuilder().email(signer2Email).signerGroupId("user").build())).sourceFiles(Arrays.asList(new FileBase(fileToSign.getId()))).parentFolder(new FolderMini(destinationFolder.getId())).build())
client.getSignRequests().createSignRequest(new SignRequestCreateRequest.SignRequestCreateRequestBuilder(Arrays.asList(new SignRequestCreateSigner.SignRequestCreateSignerBuilder().email(signerEmail).role(SignRequestCreateSignerRoleField.SIGNER).isInPerson(false).embedUrlExternalUserId("123").declinedRedirectUrl("https://www.box.com").loginRequired(false).password("password").suppressNotifications(true).build())).sourceFiles(Arrays.asList(new FileBase(fileToSign.getId()))).parentFolder(new FolderMini(destinationFolder.getId())).isDocumentPreparationNeeded(false).redirectUrl("https://www.box.com").declinedRedirectUrl("https://www.box.com").areTextSignaturesEnabled(true).emailSubject("Sign this document").emailMessage("Please sign this document").areRemindersEnabled(true).name("Sign Request").daysValid(30L).externalId("123").externalSystemName("BoxSignIntegration").build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ See the endpoint docs at

<!-- sample post_tasks -->
```
client.getTasks().createTask(new CreateTaskRequestBody.CreateTaskRequestBodyBuilder(new CreateTaskRequestBodyItemField.CreateTaskRequestBodyItemFieldBuilder().id(file.getId()).type(CreateTaskRequestBodyItemTypeField.FILE).build()).action(CreateTaskRequestBodyActionField.REVIEW).message("test message").dueAt(date).completionRule(CreateTaskRequestBodyCompletionRuleField.ALL_ASSIGNEES).build())
client.getTasks().createTask(new CreateTaskRequestBody.CreateTaskRequestBodyBuilder(new CreateTaskRequestBodyItemField.CreateTaskRequestBodyItemFieldBuilder().id(file.getId()).type(CreateTaskRequestBodyItemTypeField.FILE).build()).action(CreateTaskRequestBodyActionField.REVIEW).message("test message").dueAt(dateTime).completionRule(CreateTaskRequestBodyCompletionRuleField.ALL_ASSIGNEES).build())
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/termsofservices.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ See the endpoint docs at

<!-- sample put_terms_of_services_id -->
```
client.getTermsOfServices().updateTermsOfServiceById(tos.getId(), new UpdateTermsOfServiceByIdRequestBody(UpdateTermsOfServiceByIdRequestBodyStatusField.DISABLED, "Updated TOS"))
client.getTermsOfServices().updateTermsOfServiceById(tos.getId(), new UpdateTermsOfServiceByIdRequestBody(UpdateTermsOfServiceByIdRequestBodyStatusField.DISABLED, "TOS"))
```

### Arguments
Expand Down
2 changes: 1 addition & 1 deletion docs/trashedfiles.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ See the endpoint docs at

<!-- sample get_files_id_trash -->
```
client.getTrashedFiles().getTrashedFileById(uploadedFile.getId())
client.getTrashedFiles().getTrashedFileById(file.getId())
```

### Arguments
Expand Down
4 changes: 2 additions & 2 deletions docs/uploads.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ See the endpoint docs at

<!-- sample post_files_id_content -->
```
client.getUploads().uploadFileVersion(file.getId(), new UploadFileVersionRequestBody(new UploadFileVersionRequestBodyAttributesField(file.getName()), generateByteStream(20)))
client.getUploads().uploadFileVersion(uploadedFile.getId(), new UploadFileVersionRequestBody(new UploadFileVersionRequestBodyAttributesField(newFileVersionName), newFileContentStream))
```

### Arguments
Expand Down Expand Up @@ -92,7 +92,7 @@ See the endpoint docs at

<!-- sample post_files_content -->
```
parentClient.getUploads().uploadFile(new UploadFileRequestBody(new UploadFileRequestBodyAttributesField(getUuid(), new UploadFileRequestBodyAttributesParentField("0")), generateByteStream(1024 * 1024)))
client.getUploads().uploadFile(new UploadFileRequestBody(new UploadFileRequestBodyAttributesField(newFileName, new UploadFileRequestBodyAttributesParentField("0")), fileContentStream))
```

### Arguments
Expand Down
4 changes: 2 additions & 2 deletions docs/usercollaborations.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ See the endpoint docs at

<!-- sample delete_collaborations_id -->
```
client.getUserCollaborations().deleteCollaborationById(groupCollaboration.getId())
client.getUserCollaborations().deleteCollaborationById(collaborationId)
```

### Arguments
Expand Down Expand Up @@ -126,7 +126,7 @@ See the endpoint docs at

<!-- sample post_collaborations -->
```
client.getUserCollaborations().createCollaboration(new CreateCollaborationRequestBody(new CreateCollaborationRequestBodyItemField.CreateCollaborationRequestBodyItemFieldBuilder().type(CreateCollaborationRequestBodyItemTypeField.FILE).id(file.getId()).build(), new CreateCollaborationRequestBodyAccessibleByField.CreateCollaborationRequestBodyAccessibleByFieldBuilder(CreateCollaborationRequestBodyAccessibleByTypeField.USER).id(getEnvVar("USER_ID")).build(), CreateCollaborationRequestBodyRoleField.EDITOR))
client.getUserCollaborations().createCollaboration(new CreateCollaborationRequestBody(new CreateCollaborationRequestBodyItemField.CreateCollaborationRequestBodyItemFieldBuilder().type(CreateCollaborationRequestBodyItemTypeField.FOLDER).id(folder.getId()).build(), new CreateCollaborationRequestBodyAccessibleByField.CreateCollaborationRequestBodyAccessibleByFieldBuilder(CreateCollaborationRequestBodyAccessibleByTypeField.USER).id(user.getId()).build(), CreateCollaborationRequestBodyRoleField.EDITOR))
```

### Arguments
Expand Down
Loading

0 comments on commit 677372e

Please sign in to comment.