Custom Connector
NPM Registry
Global
The NPM Registry Connector provides access to npm package metadata via the official NPM Registry API. It lets users retrieve detailed package information, view distribution tags, fetch the latest version, and search for packages — ideal for developer portals, package-insight tools, and CI/CD pipelines.
Overview
Integration Overview
This document provides a detailed guide for each integration point using the NPM Registry Connector. The connector exposes four core endpoints for package metadata and search.
- Get Package Metadata. Retrieve full metadata for an npm package.
- Get Latest Version. Fetch metadata for the latest published version.
- Get Distribution Tags. List all distribution tags for a package.
- Search Packages. Search npm packages by keyword.
Documentation
Detailed Integration Documentation
Get Package Metadata
| Operation ID | getPackageMetadata |
|---|---|
| Endpoint | GET /{package} |
| Parameters | Required: package (path, string) — the package name (e.g. express). |
| Purpose | Retrieves full metadata for an npm package, including all versions, maintainers, and dependencies. |
| Output | JSON object with the complete package document. |
| Workflow example | Call /{package} after a user selects a package to display its details. |
Get Latest Version
| Operation ID | getLatestPackageVersion |
|---|---|
| Endpoint | GET /{package}/latest |
| Parameters | Required: package (path, string) — the package name (e.g. express). |
| Purpose | Retrieves metadata for the latest published version of a package. |
| Output | JSON object with version details. |
| Workflow example | Use in CI/CD pipelines to fetch the most recent version. |
Get Distribution Tags
| Operation ID | getPackageDistTags |
|---|---|
| Endpoint | GET /-/package/{package}/dist-tags |
| Parameters | Required: package (path, string) — the package name (e.g. express). |
| Purpose | Returns distribution tags such as latest, beta, and next. |
| Output | JSON object with tags. |
| Workflow example | Useful for release channels in package managers. |
Search Packages
| Operation ID | searchPackages |
|---|---|
| Endpoint | GET /-/v1/search |
| Parameters | Required: text (query, string) — search query (e.g. react). Optional: size (query, integer, default 5) — number of results. |
| Purpose | Searches the npm registry for packages matching keywords. |
| Output | JSON object with search results. |
| Workflow example | Used to build autocomplete or package-search features. |
Example Workflow: JavaScript Package Explorer
| Search | User searches for a package — call /-/v1/search?text=query. |
|---|---|
| Select | User selects a package — call /{package}. |
| Show version | Display the current version — call /{package}/latest. |
| Show tags | Display release tags — call /-/package/{package}/dist-tags. |
Support
For technical support, contact custom-connectors-support@isolutions.sa.