One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.
Here is an example of the request.
PATCH https://graph.microsoft.com/v1.0/deviceManagement
Content-type: application/json
Content-length: 1098
{
"@odata.type": "#microsoft.graph.deviceManagement",
"intuneBrand": {
"@odata.type": "microsoft.graph.intuneBrand",
"displayName": "Display Name value",
"themeColor": {
"@odata.type": "microsoft.graph.rgbColor",
"r": 1,
"g": 1,
"b": 1
},
"showLogo": true,
"lightBackgroundLogo": {
"@odata.type": "microsoft.graph.mimeContent",
"type": "Type value",
"value": "dmFsdWU="
},
"darkBackgroundLogo": {
"@odata.type": "microsoft.graph.mimeContent",
"type": "Type value",
"value": "dmFsdWU="
},
"showNameNextToLogo": true,
"showDisplayNameNextToLogo": true,
"contactITName": "Contact ITName value",
"contactITPhoneNumber": "Contact ITPhone Number value",
"contactITEmailAddress": "Contact ITEmail Address value",
"contactITNotes": "Contact ITNotes value",
"onlineSupportSiteUrl": "https://example.com/onlineSupportSiteUrl/",
"onlineSupportSiteName": "Online Support Site Name value",
"privacyUrl": "https://example.com/privacyUrl/"
}
}
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new DeviceManagement
{
OdataType = "#microsoft.graph.deviceManagement",
IntuneBrand = new IntuneBrand
{
OdataType = "microsoft.graph.intuneBrand",
DisplayName = "Display Name value",
ThemeColor = new RgbColor
{
OdataType = "microsoft.graph.rgbColor",
R = 1,
G = 1,
B = 1,
},
ShowLogo = true,
LightBackgroundLogo = new MimeContent
{
OdataType = "microsoft.graph.mimeContent",
Type = "Type value",
Value = Convert.FromBase64String("dmFsdWU="),
},
DarkBackgroundLogo = new MimeContent
{
OdataType = "microsoft.graph.mimeContent",
Type = "Type value",
Value = Convert.FromBase64String("dmFsdWU="),
},
ShowNameNextToLogo = true,
ShowDisplayNameNextToLogo = true,
ContactITName = "Contact ITName value",
ContactITPhoneNumber = "Contact ITPhone Number value",
ContactITEmailAddress = "Contact ITEmail Address value",
ContactITNotes = "Contact ITNotes value",
OnlineSupportSiteUrl = "https://example.com/onlineSupportSiteUrl/",
OnlineSupportSiteName = "Online Support Site Name value",
PrivacyUrl = "https://example.com/privacyUrl/",
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.DeviceManagement.PatchAsync(requestBody);
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
mgc device-management patch --body '{\
"@odata.type": "#microsoft.graph.deviceManagement",\
"intuneBrand": {\
"@odata.type": "microsoft.graph.intuneBrand",\
"displayName": "Display Name value",\
"themeColor": {\
"@odata.type": "microsoft.graph.rgbColor",\
"r": 1,\
"g": 1,\
"b": 1\
},\
"showLogo": true,\
"lightBackgroundLogo": {\
"@odata.type": "microsoft.graph.mimeContent",\
"type": "Type value",\
"value": "dmFsdWU="\
},\
"darkBackgroundLogo": {\
"@odata.type": "microsoft.graph.mimeContent",\
"type": "Type value",\
"value": "dmFsdWU="\
},\
"showNameNextToLogo": true,\
"showDisplayNameNextToLogo": true,\
"contactITName": "Contact ITName value",\
"contactITPhoneNumber": "Contact ITPhone Number value",\
"contactITEmailAddress": "Contact ITEmail Address value",\
"contactITNotes": "Contact ITNotes value",\
"onlineSupportSiteUrl": "https://example.com/onlineSupportSiteUrl/",\
"onlineSupportSiteName": "Online Support Site Name value",\
"privacyUrl": "https://example.com/privacyUrl/"\
}\
}\
'
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
// Code snippets are only available for the latest major version. Current major version is $v1.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewDeviceManagement()
intuneBrand := graphmodels.NewIntuneBrand()
displayName := "Display Name value"
intuneBrand.SetDisplayName(&displayName)
themeColor := graphmodels.NewRgbColor()
r := int32(1)
themeColor.SetR(&r)
g := int32(1)
themeColor.SetG(&g)
b := int32(1)
themeColor.SetB(&b)
intuneBrand.SetThemeColor(themeColor)
showLogo := true
intuneBrand.SetShowLogo(&showLogo)
lightBackgroundLogo := graphmodels.NewMimeContent()
type := "Type value"
lightBackgroundLogo.SetType(&type)
value := []byte("dmFsdWU=")
lightBackgroundLogo.SetValue(&value)
intuneBrand.SetLightBackgroundLogo(lightBackgroundLogo)
darkBackgroundLogo := graphmodels.NewMimeContent()
type := "Type value"
darkBackgroundLogo.SetType(&type)
value := []byte("dmFsdWU=")
darkBackgroundLogo.SetValue(&value)
intuneBrand.SetDarkBackgroundLogo(darkBackgroundLogo)
showNameNextToLogo := true
intuneBrand.SetShowNameNextToLogo(&showNameNextToLogo)
showDisplayNameNextToLogo := true
intuneBrand.SetShowDisplayNameNextToLogo(&showDisplayNameNextToLogo)
contactITName := "Contact ITName value"
intuneBrand.SetContactITName(&contactITName)
contactITPhoneNumber := "Contact ITPhone Number value"
intuneBrand.SetContactITPhoneNumber(&contactITPhoneNumber)
contactITEmailAddress := "Contact ITEmail Address value"
intuneBrand.SetContactITEmailAddress(&contactITEmailAddress)
contactITNotes := "Contact ITNotes value"
intuneBrand.SetContactITNotes(&contactITNotes)
onlineSupportSiteUrl := "https://example.com/onlineSupportSiteUrl/"
intuneBrand.SetOnlineSupportSiteUrl(&onlineSupportSiteUrl)
onlineSupportSiteName := "Online Support Site Name value"
intuneBrand.SetOnlineSupportSiteName(&onlineSupportSiteName)
privacyUrl := "https://example.com/privacyUrl/"
intuneBrand.SetPrivacyUrl(&privacyUrl)
requestBody.SetIntuneBrand(intuneBrand)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
deviceManagement, err := graphClient.DeviceManagement().Patch(context.Background(), requestBody, nil)
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
DeviceManagement deviceManagement = new DeviceManagement();
deviceManagement.setOdataType("#microsoft.graph.deviceManagement");
IntuneBrand intuneBrand = new IntuneBrand();
intuneBrand.setOdataType("microsoft.graph.intuneBrand");
intuneBrand.setDisplayName("Display Name value");
RgbColor themeColor = new RgbColor();
themeColor.setOdataType("microsoft.graph.rgbColor");
themeColor.setR(1);
themeColor.setG(1);
themeColor.setB(1);
intuneBrand.setThemeColor(themeColor);
intuneBrand.setShowLogo(true);
MimeContent lightBackgroundLogo = new MimeContent();
lightBackgroundLogo.setOdataType("microsoft.graph.mimeContent");
lightBackgroundLogo.setType("Type value");
byte[] value = Base64.getDecoder().decode("dmFsdWU=");
lightBackgroundLogo.setValue(value);
intuneBrand.setLightBackgroundLogo(lightBackgroundLogo);
MimeContent darkBackgroundLogo = new MimeContent();
darkBackgroundLogo.setOdataType("microsoft.graph.mimeContent");
darkBackgroundLogo.setType("Type value");
byte[] value1 = Base64.getDecoder().decode("dmFsdWU=");
darkBackgroundLogo.setValue(value1);
intuneBrand.setDarkBackgroundLogo(darkBackgroundLogo);
intuneBrand.setShowNameNextToLogo(true);
intuneBrand.setShowDisplayNameNextToLogo(true);
intuneBrand.setContactITName("Contact ITName value");
intuneBrand.setContactITPhoneNumber("Contact ITPhone Number value");
intuneBrand.setContactITEmailAddress("Contact ITEmail Address value");
intuneBrand.setContactITNotes("Contact ITNotes value");
intuneBrand.setOnlineSupportSiteUrl("https://example.com/onlineSupportSiteUrl/");
intuneBrand.setOnlineSupportSiteName("Online Support Site Name value");
intuneBrand.setPrivacyUrl("https://example.com/privacyUrl/");
deviceManagement.setIntuneBrand(intuneBrand);
DeviceManagement result = graphClient.deviceManagement().patch(deviceManagement);
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
const options = {
authProvider,
};
const client = Client.init(options);
const deviceManagement = {
'@odata.type': '#microsoft.graph.deviceManagement',
intuneBrand: {
'@odata.type': 'microsoft.graph.intuneBrand',
displayName: 'Display Name value',
themeColor: {
'@odata.type': 'microsoft.graph.rgbColor',
r: 1,
g: 1,
b: 1
},
showLogo: true,
lightBackgroundLogo: {
'@odata.type': 'microsoft.graph.mimeContent',
type: 'Type value',
value: 'dmFsdWU='
},
darkBackgroundLogo: {
'@odata.type': 'microsoft.graph.mimeContent',
type: 'Type value',
value: 'dmFsdWU='
},
showNameNextToLogo: true,
showDisplayNameNextToLogo: true,
contactITName: 'Contact ITName value',
contactITPhoneNumber: 'Contact ITPhone Number value',
contactITEmailAddress: 'Contact ITEmail Address value',
contactITNotes: 'Contact ITNotes value',
onlineSupportSiteUrl: 'https://example.com/onlineSupportSiteUrl/',
onlineSupportSiteName: 'Online Support Site Name value',
privacyUrl: 'https://example.com/privacyUrl/'
}
};
await client.api('/deviceManagement')
.update(deviceManagement);
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
<?php
use Microsoft\Graph\GraphServiceClient;
use Microsoft\Graph\Generated\Models\DeviceManagement;
use Microsoft\Graph\Generated\Models\IntuneBrand;
use Microsoft\Graph\Generated\Models\RgbColor;
use Microsoft\Graph\Generated\Models\MimeContent;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new DeviceManagement();
$requestBody->setOdataType('#microsoft.graph.deviceManagement');
$intuneBrand = new IntuneBrand();
$intuneBrand->setOdataType('microsoft.graph.intuneBrand');
$intuneBrand->setDisplayName('Display Name value');
$intuneBrandThemeColor = new RgbColor();
$intuneBrandThemeColor->setOdataType('microsoft.graph.rgbColor');
$intuneBrandThemeColor->setR(1);
$intuneBrandThemeColor->setG(1);
$intuneBrandThemeColor->setB(1);
$intuneBrand->setThemeColor($intuneBrandThemeColor);
$intuneBrand->setShowLogo(true);
$intuneBrandLightBackgroundLogo = new MimeContent();
$intuneBrandLightBackgroundLogo->setOdataType('microsoft.graph.mimeContent');
$intuneBrandLightBackgroundLogo->setType('Type value');
$intuneBrandLightBackgroundLogo->setValue(\GuzzleHttp\Psr7\Utils::streamFor(base64_decode('dmFsdWU=')));
$intuneBrand->setLightBackgroundLogo($intuneBrandLightBackgroundLogo);
$intuneBrandDarkBackgroundLogo = new MimeContent();
$intuneBrandDarkBackgroundLogo->setOdataType('microsoft.graph.mimeContent');
$intuneBrandDarkBackgroundLogo->setType('Type value');
$intuneBrandDarkBackgroundLogo->setValue(\GuzzleHttp\Psr7\Utils::streamFor(base64_decode('dmFsdWU=')));
$intuneBrand->setDarkBackgroundLogo($intuneBrandDarkBackgroundLogo);
$intuneBrand->setShowNameNextToLogo(true);
$intuneBrand->setShowDisplayNameNextToLogo(true);
$intuneBrand->setContactITName('Contact ITName value');
$intuneBrand->setContactITPhoneNumber('Contact ITPhone Number value');
$intuneBrand->setContactITEmailAddress('Contact ITEmail Address value');
$intuneBrand->setContactITNotes('Contact ITNotes value');
$intuneBrand->setOnlineSupportSiteUrl('https://example.com/onlineSupportSiteUrl/');
$intuneBrand->setOnlineSupportSiteName('Online Support Site Name value');
$intuneBrand->setPrivacyUrl('https://example.com/privacyUrl/');
$requestBody->setIntuneBrand($intuneBrand);
$result = $graphServiceClient->deviceManagement()->patch($requestBody)->wait();
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
Import-Module Microsoft.Graph.DeviceManagement
$params = @{
"@odata.type" = "#microsoft.graph.deviceManagement"
intuneBrand = @{
"@odata.type" = "microsoft.graph.intuneBrand"
displayName = "Display Name value"
themeColor = @{
"@odata.type" = "microsoft.graph.rgbColor"
r = 1
g = 1
b = 1
}
showLogo = $true
lightBackgroundLogo = @{
"@odata.type" = "microsoft.graph.mimeContent"
type = "Type value"
value = [System.Text.Encoding]::ASCII.GetBytes("dmFsdWU=")
}
darkBackgroundLogo = @{
"@odata.type" = "microsoft.graph.mimeContent"
type = "Type value"
value = [System.Text.Encoding]::ASCII.GetBytes("dmFsdWU=")
}
showNameNextToLogo = $true
showDisplayNameNextToLogo = $true
contactITName = "Contact ITName value"
contactITPhoneNumber = "Contact ITPhone Number value"
contactITEmailAddress = "Contact ITEmail Address value"
contactITNotes = "Contact ITNotes value"
onlineSupportSiteUrl = "https://example.com/onlineSupportSiteUrl/"
onlineSupportSiteName = "Online Support Site Name value"
privacyUrl = "https://example.com/privacyUrl/"
}
}
Update-MgDeviceManagement -BodyParameter $params
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.device_management import DeviceManagement
from msgraph.generated.models.intune_brand import IntuneBrand
from msgraph.generated.models.rgb_color import RgbColor
from msgraph.generated.models.mime_content import MimeContent
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = DeviceManagement(
odata_type = "#microsoft.graph.deviceManagement",
intune_brand = IntuneBrand(
odata_type = "microsoft.graph.intuneBrand",
display_name = "Display Name value",
theme_color = RgbColor(
odata_type = "microsoft.graph.rgbColor",
r = 1,
g = 1,
b = 1,
),
show_logo = True,
light_background_logo = MimeContent(
odata_type = "microsoft.graph.mimeContent",
type = "Type value",
value = base64.urlsafe_b64decode("dmFsdWU="),
),
dark_background_logo = MimeContent(
odata_type = "microsoft.graph.mimeContent",
type = "Type value",
value = base64.urlsafe_b64decode("dmFsdWU="),
),
show_name_next_to_logo = True,
show_display_name_next_to_logo = True,
contact_i_t_name = "Contact ITName value",
contact_i_t_phone_number = "Contact ITPhone Number value",
contact_i_t_email_address = "Contact ITEmail Address value",
contact_i_t_notes = "Contact ITNotes value",
online_support_site_url = "https://example.com/onlineSupportSiteUrl/",
online_support_site_name = "Online Support Site Name value",
privacy_url = "https://example.com/privacyUrl/",
),
)
result = await graph_client.device_management.patch(request_body)
For details about how to add the SDK to your project and create an authProvider instance, see the SDK documentation.
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.