code: func (c *Context) DownloadURL(url string) (filePath string, err error) {
  
  	ext := filepath.Ext(url)
  	out, err := ioutil.TempFile("", fmt.Sprintf("%d_%d", c.Bot().ID, c.Chat.ID))
  
  	if err != nil {
  		return "", err
  	}
  
  	out.Close()
  	os.Rename(out.Name(), out.Name()+ext)
  
  	out, err = os.OpenFile(out.Name()+ext, os.O_RDWR, 0666)
  	if err != nil {
  		return "", err
  	}
  	defer out.Close()
  
  	resp, err := http.Get(url)
  	if err != nil {
  		return "", err
  	}
  	if resp.StatusCode < 200 || resp.StatusCode > 299 {
  		return "", errors.New("non 2xx resp status")
  	}
  	defer resp.Body.Close()
  
  	_, err = io.Copy(out, resp.Body)
  	if err != nil {
  		return "", err
  	}
  
  	return out.Name(), nil
  }
docs: // DownloadURL downloads the remote URL and returns the local file path