Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Endpoint Prefix collaborations

The For more information on Box collaborations see https://developers.box.com/docs/#collaborations. The following endpoints can be invoked with the prefix collaborations as follows:

...

NameType
collabIdString
collabRequestcom.box.boxjavalibv2.requests.requestobjects.BoxCollabRequestObject
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject
folderIdString
getAllCollabsRequestcom.box.boxjavalibv2.requests.requestobjects.BoxGetAllCollabsRequestObject

Endpoint Prefix events

For more information on Box events see https://developers.box.com/docs/#events. Although this endpoint can be used by producers, Box events are better used as a consumer endpoint using the poll-events endpoint prefix. The following endpoints can be invoked with the prefix events as follows:

...

NameType
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject
eventRequestcom.box.boxjavalibv2.requests.requestobjects.BoxEventRequestObject

Endpoint Prefix groups

boxjavalibv2.requests.requestobjects.BoxEventRequestObject

Endpoint Prefix groups

For more information on Box groups see https://developers.box.com/docs/#groups. The following endpoints can be invoked with the prefix groups as follows:

...

NameType
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject
groupIdString
groupMembershipRequestcom.box.boxjavalibv2.requests.requestobjects.BoxGroupMembershipRequestObject
groupRequestcom.box.boxjavalibv2.requests.requestobjects.BoxGroupRequestObject
membershipIdString
nameString
roleString
userIdString

Endpoint Prefix search

The For more information on Box search API see https://developers.box.com/docs/#search. The following endpoints can be invoked with the prefix search as follows:

...

Endpoint Prefix comments and shared-commentsshared-comments

For more information on Box comments see https://developers.box.com/docs/#comments. The following endpoints can be invoked with the prefix comments or shared-comments as follows. The shared-comments prefix requires sharedLink and sharedPassword properties. 

...

Endpoint Prefix files and shared-files

For more information on Box files see https://developers.box.com/docs/#files. The following endpoints can be invoked with the prefix files or shared-files as follows. The shared-files prefix requires sharedLink and sharedPassword properties. 

...

NameType
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject
destinationjava.io.File
extensionString
fileIdString
fileRequestcom.box.boxjavalibv2.requests.requestobjects.BoxFileRequestObject
fileUploadRequestcom.box.restclientv2.requestsbase.BoxFileUploadRequestObject
imageRequestcom.box.boxjavalibv2.requests.requestobjects.BoxImageRequestObject
itemCopyRequestcom.box.boxjavalibv2.requests.requestobjects.BoxItemCopyRequestObject
listenercom.box.boxjavalibv2.filetransfer.IFileTransferListener
outputStreamsjava.io.OutputStream[]
sharedLinkRequestcom.box.boxjavalibv2.requests.requestobjects.BoxSharedLinkRequestObject

Endpoint Prefix folders and shared-folders

.requestobjects.BoxSharedLinkRequestObject

Endpoint Prefix folders and shared-folders

For more information on Box folders see https://developers.box.com/docs/#folders. The following endpoints can be invoked with the prefix folders or shared-folders as follows. The prefix shared-folders requires sharedLink and sharedPassword properties. 

...

Endpoint Prefix shared-items

For more information on Box shared items see https://developers.box.com/docs/#shared-items. The following endpoints can be invoked with the prefix shared-items as follows:

Code Block
    box://shared-items/endpoint?[options]

...

URI Options for shared-items

...

NameType
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject

Endpoint Prefix users

.requestsbase.BoxDefaultRequestObject

Endpoint Prefix users

For information on Box users see https://developers.box.com/docs/#users. The following endpoints can be invoked with the prefix users as follows:

Code Block
    box://users/endpoint?[options]
EndpointShorthand AliasOptionsResult Body Type
addEmailAlias emailAliasRequest, userIdcom.box.boxjavalibv2.dao.BoxEmailAlias
createEnterpriseUsercreateuserRequestcom.box.boxjavalibv2.dao.BoxUser
deleteEmailAlias defaultRequest, emailId, userId 
deleteEnterpriseUser userDeleteRequest, userId 
getAllEnterpriseUserallEnterpriseUserdefaultRequest, filterTermjava.util.List
getCurrentUsercurrentUserdefaultRequestcom.box.boxjavalibv2.dao.BoxUser
getEmailAliasesemailAliasesdefaultRequest, userIdjava.util.List
moveFolderToAnotherUser folderId, simpleUserRequest, userIdcom.box.boxjavalibv2.dao.BoxFolder
updateUserInformaitonupdateuserId, userRequestcom.box.boxjavalibv2.dao.BoxUser
updateUserPrimaryLoginupdateuserId, userUpdateLoginRequestcom.box.boxjavalibv2.dao.BoxUser
URI Options for users

 

NameType
defaultRequestcom.box.restclientv2.requestsbase.BoxDefaultRequestObject
emailAliasRequestcom.box.boxjavalibv2.requests.requestobjects.BoxEmailAliasRequestObject
emailIdString
filterTermString
folderIdString
simpleUserRequestcom.box.boxjavalibv2.requests.requestobjects.BoxSimpleUserRequestObject
userDeleteRequestcom.box.boxjavalibv2.requests.requestobjects.BoxUserDeleteRequestObject
userIdString
userRequestcom.box.boxjavalibv2.requests.requestobjects.BoxUserRequestObject
userUpdateLoginRequestcom.box.boxjavalibv2.requests.requestobjects.BoxUserRequestObject
userUpdateLoginRequestcom.box.boxjavalibv2.requests.requestobjects.BoxUserUpdateLoginRequestObject

Consumer Endpoints:

.BoxUserUpdateLoginRequestObject

Consumer Endpoints:

For more information on Box events see https://developers.box.com/docs/#events and for long polling see https://developers.box.com/docs/#events-long-polling. Consumer endpoints can only use the endpoint prefix poll-events as shown in the example next. By default the consumer will split the com.box.boxjavalibv2.dao.BoxEventCollection from every long poll and create an exchange for every com.box.boxjavalibv2.dao.BoxEvent. To make the consumer return the entire collection in a single exchange, use the URI option consumer.splitResult=false.

...

The Box component also provides a Camel type converter to convert GenericFile objects from File component to a com.box.restclientv2.requestsbase.BoxFileUploadRequestObject to upload a new file files to Box.com. The target folderId for the upload can be specified in the header property CamelBox.folderId. If the header is not specified the it value defaults to "0" for the root folder ID

Use cases

The following route uploads new files to the user's root folder:

...

Code Block
	from("box://poll-events/poll?streamPosition=-1&streamType=all&limit=100")
		.to("bean:blah");

...

The following route uses a producer with dynamic header options

...

.

...

 The fileId header has the Box file id , so its assigned to the CamelBox.fileId header in the following routeas follows:

Code Block
	from("direct:foo")
		.setHeader("CamelBox.fileId", header("fileId"))
		.to("box://files/download")
		.to("file://...");