Class UsersApi
- java.lang.Object
-
- com.zendesk.sunshine_conversations_client.api.UsersApi
-
public class UsersApi extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UserResponsecreateUser(UserCreateBody userCreateBody, java.lang.String appId)Create User Creates a new user.UserResponsecreateUser(java.lang.String bearerToken, UserCreateBody userCreateBody, java.lang.String appId)Create User Creates a new user.java.lang.ObjectdeleteUser(java.lang.String appId, java.lang.String userIdOrExternalId)Delete User Delete a user, its clients and its conversation history.java.lang.ObjectdeleteUser(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId)Delete User Delete a user, its clients and its conversation history.UserResponsedeleteUserPersonalInformation(java.lang.String appId, java.lang.String userIdOrExternalId)Delete User Personal Information Delete a user’s personal information.UserResponsedeleteUserPersonalInformation(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId)Delete User Personal Information Delete a user’s personal information.ApiClientgetApiClient()UserResponsegetUser(java.lang.String appId, java.lang.String userIdOrExternalId)Get User Fetches an individual user.UserResponsegetUser(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId)Get User Fetches an individual user.voidsetApiClient(ApiClient apiClient)UserResponseupdateUser(UserUpdateBody userUpdateBody, java.lang.String appId, java.lang.String userIdOrExternalId)Update User Updates a user.UserResponseupdateUser(java.lang.String bearerToken, UserUpdateBody userUpdateBody, java.lang.String appId, java.lang.String userIdOrExternalId)Update User Updates a user.
-
-
-
Constructor Detail
-
UsersApi
public UsersApi()
-
UsersApi
public UsersApi(ApiClient apiClient)
-
-
Method Detail
-
getApiClient
public ApiClient getApiClient()
-
setApiClient
public void setApiClient(ApiClient apiClient)
-
createUser
public UserResponse createUser(UserCreateBody userCreateBody, java.lang.String appId) throws ApiException
Create User Creates a new user.- Parameters:
userCreateBody- (required)appId- Identifies the app. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
deleteUser
public java.lang.Object deleteUser(java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiExceptionDelete User Delete a user, its clients and its conversation history. The user is considered completely deleted once the `user:delete` webhook is fired. To only delete a user’s personal information, see [Delete User Personal Information](#operation/deleteUserPersonalInformation).- Parameters:
appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
Object - Throws:
ApiException- if fails to make API call
-
deleteUserPersonalInformation
public UserResponse deleteUserPersonalInformation(java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Delete User Personal Information Delete a user’s personal information. Calling this API will clear `givenName`, `surname`, `email` and `avatarUrl` and every custom property for the specified user. For every client owned by the user, it will also clear `displayName`, `avatarUrl` and any channel specific information stored in the info and raw fields. Calling this API doesn’t delete the user’s conversation history. To fully delete the user, see [Delete User](#operation/deleteUser).- Parameters:
appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
getUser
public UserResponse getUser(java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Get User Fetches an individual user.- Parameters:
appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
updateUser
public UserResponse updateUser(UserUpdateBody userUpdateBody, java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Update User Updates a user.- Parameters:
userUpdateBody- (required)appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
createUser
public UserResponse createUser(java.lang.String bearerToken, UserCreateBody userCreateBody, java.lang.String appId) throws ApiException
Create User Creates a new user.- Parameters:
bearerToken- a token to be used for this request (required)userCreateBody- (required)appId- Identifies the app. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
deleteUser
public java.lang.Object deleteUser(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiExceptionDelete User Delete a user, its clients and its conversation history. The user is considered completely deleted once the `user:delete` webhook is fired. To only delete a user’s personal information, see [Delete User Personal Information](#operation/deleteUserPersonalInformation).- Parameters:
bearerToken- a token to be used for this request (required)appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
Object - Throws:
ApiException- if fails to make API call
-
deleteUserPersonalInformation
public UserResponse deleteUserPersonalInformation(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Delete User Personal Information Delete a user’s personal information. Calling this API will clear `givenName`, `surname`, `email` and `avatarUrl` and every custom property for the specified user. For every client owned by the user, it will also clear `displayName`, `avatarUrl` and any channel specific information stored in the info and raw fields. Calling this API doesn’t delete the user’s conversation history. To fully delete the user, see [Delete User](#operation/deleteUser).- Parameters:
bearerToken- a token to be used for this request (required)appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
getUser
public UserResponse getUser(java.lang.String bearerToken, java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Get User Fetches an individual user.- Parameters:
bearerToken- a token to be used for this request (required)appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
updateUser
public UserResponse updateUser(java.lang.String bearerToken, UserUpdateBody userUpdateBody, java.lang.String appId, java.lang.String userIdOrExternalId) throws ApiException
Update User Updates a user.- Parameters:
bearerToken- a token to be used for this request (required)userUpdateBody- (required)appId- Identifies the app. (required)userIdOrExternalId- The user's id or externalId. (required)- Returns:
- a
UserResponse - Throws:
ApiException- if fails to make API call
-
-