Indicates the status for the app log collection request if it is pending, completed or failed, Default is pending. Possible values are: pending, completed, failed, unknownFutureValue.
errorMessage
String
Indicates error message if any during the upload process.
customLogFolders
String collection
List of log folders.
completedDateTime
DateTimeOffset
Time at which the upload log request reached a completed state if not completed yet NULL will be returned.
Response
If successful, this method returns a 201 Created response code and a appLogCollectionRequest object in the response body.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new AppLogCollectionRequest
{
OdataType = "#microsoft.graph.appLogCollectionRequest",
Status = AppLogUploadState.Completed,
ErrorMessage = "Error Message value",
CustomLogFolders = new List<string>
{
"Custom Log Folders value",
},
CompletedDateTime = DateTimeOffset.Parse("2016-12-31T23:58:52.3534526-08:00"),
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.DeviceManagement.MobileAppTroubleshootingEvents["{mobileAppTroubleshootingEvent-id}"].AppLogCollectionRequests.PostAsync(requestBody);
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
AppLogCollectionRequest appLogCollectionRequest = new AppLogCollectionRequest();
appLogCollectionRequest.setOdataType("#microsoft.graph.appLogCollectionRequest");
appLogCollectionRequest.setStatus(AppLogUploadState.Completed);
appLogCollectionRequest.setErrorMessage("Error Message value");
LinkedList<String> customLogFolders = new LinkedList<String>();
customLogFolders.add("Custom Log Folders value");
appLogCollectionRequest.setCustomLogFolders(customLogFolders);
OffsetDateTime completedDateTime = OffsetDateTime.parse("2016-12-31T23:58:52.3534526-08:00");
appLogCollectionRequest.setCompletedDateTime(completedDateTime);
AppLogCollectionRequest result = graphClient.deviceManagement().mobileAppTroubleshootingEvents().byMobileAppTroubleshootingEventId("{mobileAppTroubleshootingEvent-id}").appLogCollectionRequests().post(appLogCollectionRequest);
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.app_log_collection_request import AppLogCollectionRequest
from msgraph.generated.models.app_log_upload_state import AppLogUploadState
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = AppLogCollectionRequest(
odata_type = "#microsoft.graph.appLogCollectionRequest",
status = AppLogUploadState.Completed,
error_message = "Error Message value",
custom_log_folders = [
"Custom Log Folders value",
],
completed_date_time = "2016-12-31T23:58:52.3534526-08:00",
)
result = await graph_client.device_management.mobile_app_troubleshooting_events.by_mobile_app_troubleshooting_event_id('mobileAppTroubleshootingEvent-id').app_log_collection_requests.post(request_body)
Here is an example of the response. Note: The response object shown here may be truncated for brevity. All of the properties will be returned from an actual call.