Class GetTokenForTeamsUserOptions
java.lang.Object
com.azure.communication.identity.models.GetTokenForTeamsUserOptions
- All Implemented Interfaces:
com.azure.json.JsonSerializable<GetTokenForTeamsUserOptions>
public final class GetTokenForTeamsUserOptions
extends Object
implements com.azure.json.JsonSerializable<GetTokenForTeamsUserOptions>
Options class for configuring the
CommunicationIdentityAsyncClient.getTokenForTeamsUser(GetTokenForTeamsUserOptions) and
CommunicationIdentityClient.getTokenForTeamsUser(GetTokenForTeamsUserOptions) methods.-
Constructor Summary
ConstructorsConstructorDescriptionGetTokenForTeamsUserOptions(String teamsUserAadToken, String clientId, String userObjectId) Constructor ofGetTokenForTeamsUserOptions. -
Method Summary
Modifier and TypeMethodDescriptionstatic GetTokenForTeamsUserOptionsfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of TeamsUserExchangeTokenRequest from the JsonReader.Gets the Client ID of an Azure AD application.Gets the Azure AD access token of a Teams User.Gets the Object ID of an Azure AD user (Teams User).com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
GetTokenForTeamsUserOptions
Constructor ofGetTokenForTeamsUserOptions.- Parameters:
teamsUserAadToken- Azure AD access token of a Teams User.clientId- Client ID of an Azure AD application to be verified against the appId claim in the Azure AD access token.userObjectId- Object ID of an Azure AD user (Teams User) to be verified against the OID claim in the Azure AD access token.
-
-
Method Details
-
getTeamsUserAadToken
Gets the Azure AD access token of a Teams User.- Returns:
- the Azure AD access token of a Teams User.
-
getClientId
Gets the Client ID of an Azure AD application.- Returns:
- the Client ID of an Azure AD application.
-
getUserObjectId
Gets the Object ID of an Azure AD user (Teams User).- Returns:
- the Object ID of an Azure AD user (Teams User).
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<GetTokenForTeamsUserOptions>- Throws:
IOException
-
fromJson
public static GetTokenForTeamsUserOptions fromJson(com.azure.json.JsonReader jsonReader) throws IOException Reads an instance of TeamsUserExchangeTokenRequest from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of TeamsUserExchangeTokenRequest if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException- If the deserialized JSON object was missing any required properties.IOException- If an error occurs while reading the TeamsUserExchangeTokenRequest.
-