module GoogleMusicApi::Http

Private Instance Methods

make_get_request(url, options = {}) click to toggle source
# File lib/google_music_api/http.rb, line 6
def make_get_request(url, options = {})
  url ="#{self.class::SERVICE_ENDPOINT}#{url}"
  options[:headers] = {'Authorization': 'GoogleLogin auth='+authorization_token}
  HTTParty.get(url, options).parsed_response
end
make_post_request(url, options = {}) click to toggle source
# File lib/google_music_api/http.rb, line 12
def make_post_request(url, options = {})
  url ="#{self.class::SERVICE_ENDPOINT}#{url}"
  options[:headers] = {'Authorization': 'GoogleLogin auth='+authorization_token, 'Content-Type': 'application/json'}
  HTTParty.post(url, options).parsed_response
end