microsoft-graph-devx-api
microsoft-graph-devx-api copied to clipboard
wrong snippets for java onedrive/onenote/sharepoint content download
Fore the following pages:
- https://docs.microsoft.com/en-us/graph/api/driveitem-get-content?view=graph-rest-1.0&tabs=java
- https://docs.microsoft.com/en-us/graph/api/driveitem-get-content-format?view=graph-rest-1.0&tabs=java
- https://docs.microsoft.com/en-us/graph/api/resource-get?view=graph-rest-1.0&tabs=java
the sample should be along the lines of
IGraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
InputStream stream = graphClient
.me()
.drive()
.items(itemId)
.content()
.buildRequest()
.get();
and not using the custom request builder.
Related to
- https://github.com/microsoftgraph/msgraph-sdk-java/issues/331
- https://github.com/microsoftgraph/msgraph-sdk-java/issues/309 AB#6993