<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def buildUrl(self, cache_friendly=False):
 """ Construct the URL to get the sound from Goggle API. If cache_friendly is True, remove token from URL to use as a cache key. """

    params = collections.OrderedDict()
    params["client"] = "tw-ob"
    params["ie"] = "UTF-8"
    params["idx"] = str(self.segment_num)
    if self.segment_count is not None:
      params["total"] = str(self.segment_count)
    params["textlen"] = str(len(self.text))
    params["tl"] = self.lang
    lower_text = self.text.lower()
    params["q"] = lower_text
    return "%s?%s" % (__class__.BASE_URL, urllib.parse.urlencode(params))