code: public static void setUsername(final String username) {
          if (username == null) {
              throw new AuthenticationException("Username can not be null");
          }
  
          if (!username.equals(Twilio.username)) {
              Twilio.invalidate();
          }
  
          Twilio.username = username;
      }
docs: Set the username.
  
  @param username account sid to use
  @throws AuthenticationException if accountSid is null