Versions in this module Expand all Collapse all v0 v0.1.0 Jun 14, 2026 Changes in this version + const DefaultUserAgent + const Host + var ErrNotFound = errors.New("not found") + type Client struct + func NewClient(cfg Config) *Client + func (c *Client) Deps(ctx context.Context, name string) ([]Dependency, error) + func (c *Client) Downloads(ctx context.Context, name, period string) (*Downloads, error) + func (c *Client) Info(ctx context.Context, name string) (*Package, error) + func (c *Client) Search(ctx context.Context, query string, limit int) ([]SearchResult, error) + func (c *Client) Version(ctx context.Context, name, version string) (*PackageVersion, error) + type Config struct + DownloadsURL string + Rate time.Duration + RegistryURL string + Retries int + Timeout time.Duration + UserAgent string + func DefaultConfig() Config + type Dependency struct + Constraint string + Kind string + Name string + type Domain struct + func (Domain) Classify(input string) (uriType, id string, err error) + func (Domain) Info() kit.DomainInfo + func (Domain) Locate(uriType, id string) (string, error) + func (Domain) Register(app *kit.App) + type Downloads struct + Downloads int + End string + Package string + Start string + type Package struct + Author string + Created string + Description string + Homepage string + Keywords []string + License string + Modified string + Name string + Readme string + Repository string + URL string + Version string + type PackageVersion struct + Author string + Dependencies map[string]string + Description string + DevDependencies map[string]string + Homepage string + Keywords []string + License string + Name string + URL string + Version string + type SearchResult struct + Description string + Keywords []string + Name string + Rank int + ScoreFinal float64 + URL string + Version string