code: func NewEndpoint(host string, port int, https bool, insecure bool, Cacert, cert, key []byte, timeout time.Duration) *Endpoint {
  	endpoint := &Endpoint{
  		Host:     host,
  		Port:     port,
  		HTTPS:    https,
  		Insecure: insecure,
  		CACert:   Cacert,
  		Key:      key,
  		Cert:     cert,
  	}
  	// if the timeout was set
  	if timeout != 0 {
  		endpoint.Timeout = timeout
  	} else {
  		// assign default 60sec timeout
  		endpoint.Timeout = 60 * time.Second
  	}
  
  	return endpoint
  }
docs: // NewEndpoint returns new pointer to struct Endpoint, with a default 60s response header timeout