POST https://graph.microsoft.com/v1.0/deviceManagement/remoteAssistancePartners
Content-type: application/json
Content-length: 266
{
"@odata.type": "#microsoft.graph.remoteAssistancePartner",
"displayName": "Display Name value",
"onboardingUrl": "https://example.com/onboardingUrl/",
"onboardingStatus": "onboarding",
"lastConnectionDateTime": "2016-12-31T23:58:36.6670033-08:00"
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new RemoteAssistancePartner
{
OdataType = "#microsoft.graph.remoteAssistancePartner",
DisplayName = "Display Name value",
OnboardingUrl = "https://example.com/onboardingUrl/",
OnboardingStatus = RemoteAssistanceOnboardingStatus.Onboarding,
LastConnectionDateTime = DateTimeOffset.Parse("2016-12-31T23:58:36.6670033-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.RemoteAssistancePartners.PostAsync(requestBody);
// Code snippets are only available for the latest major version. Current major version is $v1.*
// Dependencies
import (
"context"
"time"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewRemoteAssistancePartner()
displayName := "Display Name value"
requestBody.SetDisplayName(&displayName)
onboardingUrl := "https://example.com/onboardingUrl/"
requestBody.SetOnboardingUrl(&onboardingUrl)
onboardingStatus := graphmodels.ONBOARDING_REMOTEASSISTANCEONBOARDINGSTATUS
requestBody.SetOnboardingStatus(&onboardingStatus)
lastConnectionDateTime , err := time.Parse(time.RFC3339, "2016-12-31T23:58:36.6670033-08:00")
requestBody.SetLastConnectionDateTime(&lastConnectionDateTime)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
remoteAssistancePartners, err := graphClient.DeviceManagement().RemoteAssistancePartners().Post(context.Background(), requestBody, nil)
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
RemoteAssistancePartner remoteAssistancePartner = new RemoteAssistancePartner();
remoteAssistancePartner.setOdataType("#microsoft.graph.remoteAssistancePartner");
remoteAssistancePartner.setDisplayName("Display Name value");
remoteAssistancePartner.setOnboardingUrl("https://example.com/onboardingUrl/");
remoteAssistancePartner.setOnboardingStatus(RemoteAssistanceOnboardingStatus.Onboarding);
OffsetDateTime lastConnectionDateTime = OffsetDateTime.parse("2016-12-31T23:58:36.6670033-08:00");
remoteAssistancePartner.setLastConnectionDateTime(lastConnectionDateTime);
RemoteAssistancePartner result = graphClient.deviceManagement().remoteAssistancePartners().post(remoteAssistancePartner);
<?php
use Microsoft\Graph\GraphServiceClient;
use Microsoft\Graph\Generated\Models\RemoteAssistancePartner;
use Microsoft\Graph\Generated\Models\RemoteAssistanceOnboardingStatus;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new RemoteAssistancePartner();
$requestBody->setOdataType('#microsoft.graph.remoteAssistancePartner');
$requestBody->setDisplayName('Display Name value');
$requestBody->setOnboardingUrl('https://example.com/onboardingUrl/');
$requestBody->setOnboardingStatus(new RemoteAssistanceOnboardingStatus('onboarding'));
$requestBody->setLastConnectionDateTime(new \DateTime('2016-12-31T23:58:36.6670033-08:00'));
$result = $graphServiceClient->deviceManagement()->remoteAssistancePartners()->post($requestBody)->wait();
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.remote_assistance_partner import RemoteAssistancePartner
from msgraph.generated.models.remote_assistance_onboarding_status import RemoteAssistanceOnboardingStatus
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = RemoteAssistancePartner(
odata_type = "#microsoft.graph.remoteAssistancePartner",
display_name = "Display Name value",
onboarding_url = "https://example.com/onboardingUrl/",
onboarding_status = RemoteAssistanceOnboardingStatus.Onboarding,
last_connection_date_time = "2016-12-31T23:58:36.6670033-08:00",
)
result = await graph_client.device_management.remote_assistance_partners.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.