code: func (c *Client) buildURLForRequest(urlStr string) (string, error) {
  	// If there is a "/" at the start, remove it.
  	// TODO: It can be arranged for all callers of buildURLForRequest to never have a "/" prefix,
  	//       which can be ensured via tests. This is how it's done in go-github.
  	//       Then, this run-time check becomes unnecessary and can be removed.
  	urlStr = strings.TrimPrefix(urlStr, "/")
  
  	// If we are authenticated, let's apply the "a/" prefix,
  	// but only if it has not already been applied.
  	if c.Authentication.HasAuth() && !strings.HasPrefix(urlStr, "a/") {
  		urlStr = "a/" + urlStr
  	}
  
  	rel, err := url.Parse(urlStr)
  	if err != nil {
  		return "", err
  	}
  
  	return c.baseURL.String() + rel.String(), nil
  }
docs: // buildURLForRequest will build the URL (as string) that will be called.
  // We need such a utility method, because the URL.Path needs to be escaped (partly).
  //
  // E.g. if a project is called via "projects/%s" and the project is named "plugin/delete-project"
  // there has to be "projects/plugin%25Fdelete-project" instead of "projects/plugin/delete-project".
  // The second url will return nothing.