ITに関する備忘録

日々の業務で利用した技術関連について、忘れないようにメモしています。

AzueADのスキーマ拡張について

以下のサイトに記載がありますね。
https://docs.microsoft.com/ja-jp/azure/active-directory/develop/active-directory-schema-extensions

 

ただし、名称が以下のようになるみたいで微妙ですね。

===

ディレクトスキーマ拡張属性の識別子は、Extension_xxxxxxxxx_AttributeName の形式です。 ここで xxxxxxxxx は、拡張機能が定義されたアプリケーションの applicationId です。

===

 

設定自体は、GraphだけでなくPowerShellでもできるようです。

 

$MyApp = (New-AzureADApplication -DisplayName "My Properties Bag" -IdentifierUris "https://dummy").ObjectId
Note that you need to create a service principal for this application in your directory as well, so you can create a new extension property:

New-AzureADServicePrincipal -AppId (Get-AzureADApplication -SearchString "My Properties Bag").AppId
Now we can use this application to create a new extension property:

New-AzureADApplicationExtensionProperty -ObjectId $MyApp -Name "MyNewProperty" -DataType "String" -TargetObjects "User"
When the cmdlet completes successfully it returns the new extension attribute object:

▼参考サイト

https://docs.microsoft.com/ja-jp/powershell/azure/active-directory/using-extension-attributes-sample?view=azureadps-2.0