microsoftgraph / microsoftgraph/msgraph-metadata
Commit Win32LobApp missing `deviceAppManagement/mobileApps/{id}/microsoft.graph.win32LobApp/contentVersions/{contentVersionId}/files/{fileId}/commit`
Nobody has claimed this yet.
- Dominant language
- XSLT
- Stars
- 166
- Forks
- 55
- Avg merge
- 16h 12m
- Merged PRs (30d)
- 14
Description
There is absolutely no documentation on how to commit a file once uploaded.
Related missing paths:
deviceAppManagement/mobileApps/{appId}/microsoft.graph.win32LobApp/contentVersionsdeviceAppManagement/mobileApps/{appId}/microsoft.graph.win32LobApp/contentVersions/{contentVersionId}/filesdeviceAppManagement/mobileApps/{appId}/microsoft.graph.win32LobApp/contentVersions/{contentVersionId}/files/{fileId}deviceAppManagement/mobileApps/{appId}/microsoft.graph.win32LobApp/contentVersions/{contentVersionId}/files/{fileId}/commit
Working solution for other facing this issue
Here is my Graph SDK .NET hack extension method (as part of WinTuner):
public static Task Intune_CommitWin32LobAppContentVersionFileAsync(this GraphServiceClient graphServiceClient, string win32LobAppId, string contentVersionId, string mobileAppContentFileId, FileEncryptionInfo fileEncryptionInfo, CancellationToken cancellationToken = default)
{
ArgumentNullException.ThrowIfNull(graphServiceClient);
ArgumentException.ThrowIfNullOrEmpty(win32LobAppId);
ArgumentException.ThrowIfNullOrEmpty(contentVersionId);
ArgumentException.ThrowIfNullOrEmpty(mobileAppContentFileId);
ArgumentNullException.ThrowIfNull(fileEncryptionInfo);
var body = new MobileAppContentFileCommitBody
{
FileEncryptionInfo = fileEncryptionInfo,
};
var data = JsonSerializer.SerializeToUtf8Bytes(body, new JsonSerializerOptions { PropertyNamingPolicy = JsonNamingPolicy.CamelCase });
var requestInfo = new RequestInformation
{
HttpMethod = Method.POST,
Content = new MemoryStream(data),
URI = new Uri($"https://graph.microsoft.com/beta/deviceAppManagement/mobileApps/{win32LobAppId}/microsoft.graph.win32LobApp/contentVersions/{contentVersionId}/files/{mobileAppContentFileId}/commit"),
};
requestInfo.Headers.Add("Content-Type", "application/json");
return graphServiceClient.RequestAdapter.SendNoContentAsync(requestInfo, errorMapping: ErrorMapping, cancellationToken: cancellationToken);
}
This issue is related to #510 as in things missing in the app management stuff.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the four missing Microsoft Graph paths in the issue and review the related #510 discussion. Use GraphServiceClientExtensions.cs in the linked WinTuner example to understand the commit operation and compare it with existing app-management metadata. Done means the content-version, file, and commit paths are documented with the required commit request details.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- api, documentation
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100