Language

WebPubSubChatServiceClient.GetUser Method

Definition

Overloads

Name Description
GetUser(String, RequestContext)

[Protocol Method] Get a user's profile. The response is a polymorphic ChatUser (e.g. HumanChatUser) selected by the kind discriminator.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
GetUser(String, CancellationToken)

Get a user's profile. The response is a polymorphic ChatUser (e.g. HumanChatUser) selected by the kind discriminator.

GetUser(String, RequestContext)

Source:
WebPubSubChatServiceClient.cs

[Protocol Method] Get a user's profile. The response is a polymorphic ChatUser (e.g. HumanChatUser) selected by the kind discriminator.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual Azure.Response GetUser(string userId, Azure.RequestContext context);
abstract member GetUser : string * Azure.RequestContext -> Azure.Response
override this.GetUser : string * Azure.RequestContext -> Azure.Response
Public Overridable Function GetUser (userId As String, context As RequestContext) As Response

Parameters

userId
String

User identifier.

context
RequestContext

The request options, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

userId is null.

userId is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to

GetUser(String, CancellationToken)

Source:
WebPubSubChatServiceClient.cs

Get a user's profile. The response is a polymorphic ChatUser (e.g. HumanChatUser) selected by the kind discriminator.

public virtual Azure.Response<Azure.Messaging.WebPubSub.Chat.WebPubSubChatUser> GetUser(string userId, System.Threading.CancellationToken cancellationToken = default);
abstract member GetUser : string * System.Threading.CancellationToken -> Azure.Response<Azure.Messaging.WebPubSub.Chat.WebPubSubChatUser>
override this.GetUser : string * System.Threading.CancellationToken -> Azure.Response<Azure.Messaging.WebPubSub.Chat.WebPubSubChatUser>
Public Overridable Function GetUser (userId As String, Optional cancellationToken As CancellationToken = Nothing) As Response(Of WebPubSubChatUser)

Parameters

userId
String

User identifier.

cancellationToken
CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Exceptions

userId is null.

userId is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to