return result;
}
@Test
public void testCreateSharedLink() throws Exception {
final BoxFile boxFile = copyFile();
try {
final Map<String, Object> headers = new HashMap<String, Object>();
// parameter type is String
headers.put("CamelBox.fileId", boxFile.getId());
// parameter type is com.box.boxjavalibv2.requests.requestobjects.BoxSharedLinkRequestObject
final BoxSharedLinkRequestEntity sharedLink = new BoxSharedLinkRequestEntity(BoxSharedLinkAccess.OPEN);
final BoxSharedLinkRequestObject requestObject =
BoxSharedLinkRequestObject.createSharedLinkRequestObject(sharedLink);
headers.put("CamelBox.sharedLinkRequest", requestObject);
BoxFile result = requestBodyAndHeaders("direct://CREATESHAREDLINK", null, headers);
assertNotNull("createSharedLink result", result);
LOG.debug("createSharedLink: " + result);
} finally {
deleteFile(boxFile.getId());