Package zendeskapi.models.users

Examples of zendeskapi.models.users.IndividualUserResponse


      throw new ZendeskApiException(e);
    }
  }

  public IndividualUserResponse createUser(User user) throws ZendeskApiException {
    IndividualUserResponse body = new IndividualUserResponse();
    body.setUser(user);
    try {
      return genericPost("users.json", body, IndividualUserResponse.class);
    } catch (Exception e) {
      throw new ZendeskApiException("Failed to create user " + user.getName(), e);
    }
View Full Code Here


    user.setSuspended(true);
    return updateUser(user);
  }

  public IndividualUserResponse updateUser(User user) throws ZendeskApiException {
    IndividualUserResponse userToUpdate = new IndividualUserResponse();
    userToUpdate.setUser(user);
    try {
      return genericPut(getUserIdUri(user.getId()) + ".json", userToUpdate, IndividualUserResponse.class);
    } catch (Exception e) {
      throw new ZendeskApiException("Could not update user id " + user.getId(), e);
    }
View Full Code Here

TOP

Related Classes of zendeskapi.models.users.IndividualUserResponse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.