notificationMessageTemplate の作成
名前空間: microsoft.graph
注: Intune 用 Microsoft Graph API には、テナントの 有効な Intune ライセンスが必要です。
新しい notificationMessageTemplate オブジェクトを作成します。
前提条件
この API を呼び出すには、次のいずれかのアクセス許可が必要です。アクセス許可の選択方法などの詳細については、「アクセス許可」を参照してください。
| アクセス許可の種類 | アクセス許可 (特権の小さいものから大きいものへ) |
|---|---|
| 委任 (職場または学校のアカウント) | DeviceManagementServiceConfig.ReadWrite.All |
| 委任 (個人用 Microsoft アカウント) | サポートされていません。 |
| アプリケーション | DeviceManagementServiceConfig.ReadWrite.All |
HTTP 要求
POST /deviceManagement/notificationMessageTemplates
要求ヘッダー
| ヘッダー | 値 |
|---|---|
| Authorization | ベアラー <トークン> が必要です。 |
| 承諾 | application/json |
要求本文
要求の本文で、notificationMessageTemplate オブジェクトの JSON 表記を指定します。
次の表に、notificationMessageTemplate の作成時に必要なプロパティを示します。
| プロパティ | 型 | 説明 |
|---|---|---|
| id | String | エンティティのキー。 |
| lastModifiedDateTime | DateTimeOffset | オブジェクトの最終更新の DateTime。 |
| displayName | String | 通知メッセージ テンプレートの表示名。 |
| defaultLocale | String | 要求されたロケールが使用できないときにフォールバックする既定のロケール。 |
| brandingOptions | notificationTemplateBrandingOptions | メッセージ テンプレートのブランド化オプション。 ブランド化は、Intune 管理コンソールで定義されます。 可能な値は、none、includeCompanyLogo、includeCompanyName、includeContactInformation、includeDeviceDetails です。 |
応答
成功した場合、このメソッドは 201 Created 応答コードと、応答本文で notificationMessageTemplate オブジェクトを返します。
例
要求
以下は、要求の例です。
POST https://graph.microsoft.com/v1.0/deviceManagement/notificationMessageTemplates
Content-type: application/json
Content-length: 197
{
"@odata.type": "#microsoft.graph.notificationMessageTemplate",
"displayName": "Display Name value",
"defaultLocale": "Default Locale value",
"brandingOptions": "includeCompanyLogo"
}
応答
以下は、応答の例です。注:簡潔にするために、ここに示す応答オブジェクトは切り詰められている場合があります。すべてのプロパティは実際の呼び出しから返されます。
HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 310
{
"@odata.type": "#microsoft.graph.notificationMessageTemplate",
"id": "e1db399b-399b-e1db-9b39-dbe19b39dbe1",
"lastModifiedDateTime": "2017-01-01T00:00:35.1329464-08:00",
"displayName": "Display Name value",
"defaultLocale": "Default Locale value",
"brandingOptions": "includeCompanyLogo"
}
フィードバック
フィードバックの送信と表示