func NewRequesterWithClient(url, version string, cli *http.Client) (*Requester, error) {
	if err := ValidateURL(url); err != nil {
		return nil, err
	}
	if err := ValidateAPIVersion(version); err != nil {
		return nil, err
	}
	if !strings.HasSuffix(url, "/") {
		url += "/"
	}
	return &Requester{
		cli:    cli,
		url:    url,
		prefix: "api/" + version,
	}, nil
}
NewRequesterWithClient creates a new requester with a custom HTTP client.
package client
import (
	"bytes"
	"encoding/json"
	"fmt"
	"io"
	"net/http"
	"net/url"
	"path"
	"strings"
)
type Requester struct {
	cli    *http.Client
	url    string
	prefix string
}
func NewRequester(url, version string) (*Requester, error) {
	return NewRequesterWithClient(url, version, http.DefaultClient)
}