code: func (c *globalClient) Lookup(device protocol.DeviceID) (addresses []string, err error) {
  	if c.noLookup {
  		return nil, lookupError{
  			error:    errors.New("lookups not supported"),
  			cacheFor: time.Hour,
  		}
  	}
  
  	qURL, err := url.Parse(c.server)
  	if err != nil {
  		return nil, err
  	}
  
  	q := qURL.Query()
  	q.Set("device", device.String())
  	qURL.RawQuery = q.Encode()
  
  	resp, err := c.queryClient.Get(qURL.String())
  	if err != nil {
  		l.Debugln("globalClient.Lookup", qURL, err)
  		return nil, err
  	}
  	if resp.StatusCode != 200 {
  		resp.Body.Close()
  		l.Debugln("globalClient.Lookup", qURL, resp.Status)
  		err := errors.New(resp.Status)
  		if secs, atoiErr := strconv.Atoi(resp.Header.Get("Retry-After")); atoiErr == nil && secs > 0 {
  			err = lookupError{
  				error:    err,
  				cacheFor: time.Duration(secs) * time.Second,
  			}
  		}
  		return nil, err
  	}
  
  	bs, err := ioutil.ReadAll(resp.Body)
  	if err != nil {
  		return nil, err
  	}
  	resp.Body.Close()
  
  	var ann announcement
  	err = json.Unmarshal(bs, &ann)
  	return ann.Addresses, err
  }
docs: // Lookup returns the list of addresses where the given device is available