def get_user(username)
      token = self.auth_token()
      result = HTTParty.get("#{@head_url}/users/#{username}", :headers => { 'Content-Type' => 'application/json', 'Authorization'=>"Bearer #{token}" } )
      
      if result.response.code.to_i == 200
        return result["entities"][0] 
      else
        nil
      end

    end
def get_user(username)
      token = self.auth_token()
      result = HTTParty.get("#{@head_url}/users/#{username}", :headers => { 'Content-Type' => 'application/json', 'Authorization'=>"Bearer #{token}" } )
      
      if result.response.code.to_i == 200
        return result["entities"][0] 
      else
        nil
      end

    end
获取环信上的用户