identityUserFlowAttribute の更新
[アーティクル]
12/06/2021
3 人の共同作成者
この記事の内容
名前空間: microsoft.graph
identityUserFlowAttribute オブジェクトのプロパティを更新 します。 更新できるのは、ユーザー フローのカスタム属性のみです。
アクセス許可
この API を呼び出すには、次のいずれかのアクセス許可が必要です。アクセス許可の選択方法などの詳細については、「アクセス許可 」を参照してください。
アクセス許可の種類
アクセス許可 (特権の小さいものから大きいものへ)
委任 (職場または学校のアカウント)
IdentityUserFlow.ReadWrite.All
委任 (個人用 Microsoft アカウント)
サポートされていません。
アプリケーション
IdentityUserFlow.ReadWrite.All
仕事または学校のアカウントは、次のいずれかの役割に属している必要があります。
全体管理者
外部 ID ユーザー Flow属性管理者
HTTP 要求
PATCH /identity/userFlowAttributes/{id}
名前
説明
Authorization
ベアラー {token}。必須。
Content-Type
application/json. Required.
要求本文
要求本文で 、IDENTITYUserFlowAttribute オブジェクトの更新が必要な 1 つ以上のプロパティを JSON オブジェクトに指定します。
注: description プロパティのみを 更新できます。
プロパティ
型
説明
description
String
ユーザー フロー属性の説明。 サインアップ時にユーザーに表示されます。
応答
成功した場合、このメソッドは 204 No Content 応答コードを返します。 失敗した場合、4xx エラーが詳細情報とともに返されます。
例
要求
要求の例を次に示します。
PATCH https://graph.microsoft.com/v1.0/identity/userFlowAttributes/extension_d09380e2b4c642b9a203fb816a04a7ad_Hobby
Content-type: application/json
{
"description": "Your new hobby"
}
GraphServiceClient graphClient = new GraphServiceClient( authProvider );
var identityUserFlowAttribute = new IdentityUserFlowAttribute
{
Description = "Your new hobby"
};
await graphClient.Identity.UserFlowAttributes["{identityUserFlowAttribute-id}"]
.Request()
.UpdateAsync(identityUserFlowAttribute);
SDK をプロジェクトに追加し、authProvider インスタンスを作成する 方法の詳細については、SDK のドキュメントを参照してください 。
const options = {
authProvider,
};
const client = Client.init(options);
const identityUserFlowAttribute = {
description: 'Your new hobby'
};
await client.api('/identity/userFlowAttributes/extension_d09380e2b4c642b9a203fb816a04a7ad_Hobby')
.update(identityUserFlowAttribute);
SDK をプロジェクトに追加し、authProvider インスタンスを作成する 方法の詳細については、SDK のドキュメントを参照してください 。
MSHTTPClient *httpClient = [MSClientFactory createHTTPClientWithAuthenticationProvider:authenticationProvider];
NSString *MSGraphBaseURL = @"https://graph.microsoft.com/v1.0/";
NSMutableURLRequest *urlRequest = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:[MSGraphBaseURL stringByAppendingString:@"/identity/userFlowAttributes/extension_d09380e2b4c642b9a203fb816a04a7ad_Hobby"]]];
[urlRequest setHTTPMethod:@"PATCH"];
[urlRequest setValue:@"application/json" forHTTPHeaderField:@"Content-Type"];
MSGraphIdentityUserFlowAttribute *identityUserFlowAttribute = [[MSGraphIdentityUserFlowAttribute alloc] init];
[identityUserFlowAttribute setDescription:@"Your new hobby"];
NSError *error;
NSData *identityUserFlowAttributeData = [identityUserFlowAttribute getSerializedDataWithError:&error];
[urlRequest setHTTPBody:identityUserFlowAttributeData];
MSURLSessionDataTask *meDataTask = [httpClient dataTaskWithRequest:urlRequest
completionHandler: ^(NSData *data, NSURLResponse *response, NSError *nserror) {
//Request Completed
}];
[meDataTask execute];
SDK をプロジェクトに追加し、authProvider インスタンスを作成する 方法の詳細については、SDK のドキュメントを参照してください 。
GraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
IdentityUserFlowAttribute identityUserFlowAttribute = new IdentityUserFlowAttribute();
identityUserFlowAttribute.description = "Your new hobby";
graphClient.identity().userFlowAttributes("extension_d09380e2b4c642b9a203fb816a04a7ad_Hobby")
.buildRequest()
.patch(identityUserFlowAttribute);
SDK をプロジェクトに追加し、authProvider インスタンスを作成する 方法の詳細については、SDK のドキュメントを参照してください 。
//THE GO SDK IS IN PREVIEW. NON-PRODUCTION USE ONLY
graphClient := msgraphsdk.NewGraphServiceClient(requestAdapter)
requestBody := msgraphsdk.NewIdentityUserFlowAttribute()
description := "Your new hobby"
requestBody.SetDescription(&description)
identityUserFlowAttributeId := "identityUserFlowAttribute-id"
graphClient.Identity().UserFlowAttributesById(&identityUserFlowAttributeId).Patch(requestBody)
SDK をプロジェクトに追加し、authProvider インスタンスを作成する 方法の詳細については、SDK のドキュメントを参照してください 。
応答
応答の例を次に示します。
HTTP/1.1 204 No Content