Skip to content

npm API

8 endpointsDeveloper & TechGlobalsocial:read7 real examples

Returns npm packages from search, with versions, dist-tags, licences, dependencies and download counts.

View as Markdown
GET/npm/searchPackages that match a search, 20 per page, best match first.
GET/npm/packageLatest version, licence, maintainers and last-week downloads of one package.
GET/npm/versionsPublished versions of one package, newest first, 30 per page, with the publish time and any deprecation message.
GET/npm/versionOne version of a package: its licence, dependencies, tarball and integrity hash. latest when no version is given.
GET/npm/distTagsThe dist-tags of one package, such as latest, next and beta, with the version each one points to.
GET/npm/downloadsDownloads of one package over a period: its total and the count of each day.
GET/npm/maintainerPackagesPackages one npm user maintains, as the registry search ranks them, 20 per page.
GET/npm/orgPackagesPackages of one npm organization (scope such as @sveltejs), sorted by name, 100 per page.

package

GET/v1/npm/package

Latest version, licence, maintainers and last-week downloads of one package.

scope social:read1 unitcached 1 h

Parameters

name
string
required
Package name, scoped names included (@scope/name), or npmjs.com package URL.
e.g. react
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

13 fields
authorstring
dependencyCountinteger (int64)
deprecatedstring
descriptionstring
downloadsLastWeekinteger (int64)
homepagestring
keywordsstring[]
licensestring
maintainersstring[]
namestring
repositorystring
urlstring
versionstring
curl "https://api.hoshime.com/v1/npm/package?name=react" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": {
    "author": "",
    "dependencyCount": 0,
    "deprecated": "",
    "description": "React is a JavaScript library for building user interfaces.",
    "downloadsLastWeek": 250126673,
    "homepage": "https://react.dev/",
    "keywords": [
      "react"
    ],
    "license": "MIT",
    "maintainers": [
      "fb",
      "react-bot"
    ],
    "name": "react",
    "repository": "git+https://github.com/react/react.git",
    "url": "https://www.npmjs.com/package/react",
    "version": "19.3.1"
  },
  "meta": {
    "cached": false,
    "endpoint": "package",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

versions

GET/v1/npm/versions

Published versions of one package, newest first, 30 per page, with the publish time and any deprecation message.

scope social:read1 unitcached 1 hpaginated

Parameters

name
string
required
Package name, scoped names included (@scope/name), or npmjs.com package URL.
e.g. react
cursor
string
meta.pagination.nextCursor of the previous page. Omit it for the first page.
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

3 fields
deprecatedstring
publishedAtstring
versionstring
curl "https://api.hoshime.com/v1/npm/versions?name=react" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": [
    {
      "deprecated": "",
      "publishedAt": "2026-11-06T16:19:15.622Z",
      "version": "0.0.0-experimental-5b610964-20261106"
    },
    {
      "deprecated": "",
      "publishedAt": "2026-11-06T16:18:36.333Z",
      "version": "19.3.0-canary-5b610964-20261106"
    }
  ],
  "meta": {
    "cached": false,
    "endpoint": "versions",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "pagination": {
      "nextCursor": "EpcDEgV…",
      "hasMore": true,
      "total": null
    },
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

version

GET/v1/npm/version

One version of a package: its licence, dependencies, tarball and integrity hash. latest when no version is given.

scope social:read1 unitcached 24 h

Parameters

name
string
required
Package name, scoped names included (@scope/name), or npmjs.com package URL.
e.g. react
version
string
Exact version, such as 18.3.1, or a dist-tag such as next. Default latest.
e.g. 18.3.1
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

12 fields
dependenciesDependency[]
namestring
rangestring
deprecatedstring
descriptionstring
fileCountinteger (int64)
integritystring
licensestring
namestring
tarballstring
unpackedSizeinteger (int64)
versionstring
curl "https://api.hoshime.com/v1/npm/version?name=react&version=18.3.1" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": {
    "dependencies": [
      {
        "name": "loose-envify",
        "range": "^1.1.0"
      }
    ],
    "deprecated": "",
    "description": "React is a JavaScript library for building user interfaces.",
    "fileCount": 20,
    "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==",
    "license": "MIT",
    "name": "react",
    "tarball": "https://registry.npmjs.org/react/-/react-18.3.1.tgz",
    "unpackedSize": 318101,
    "version": "18.3.1"
  },
  "meta": {
    "cached": false,
    "endpoint": "version",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

distTags

GET/v1/npm/distTags

The dist-tags of one package, such as latest, next and beta, with the version each one points to.

scope social:read1 unitcached 1 hpaginated

Parameters

name
string
required
Package name, scoped names included (@scope/name), or npmjs.com package URL.
e.g. react
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

2 fields
tagstring
versionstring
curl "https://api.hoshime.com/v1/npm/distTags?name=react" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": [
    {
      "tag": "backport",
      "version": "19.1.10"
    },
    {
      "tag": "beta",
      "version": "19.0.0-beta-26f2496093-20240514"
    }
  ],
  "meta": {
    "cached": false,
    "endpoint": "distTags",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "pagination": {
      "nextCursor": "EpcDEgV…",
      "hasMore": true,
      "total": null
    },
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

downloads

GET/v1/npm/downloads

Downloads of one package over a period: its total and the count of each day.

scope social:read1 unitcached 1 h

Parameters

name
string
required
Package name, scoped names included (@scope/name), or npmjs.com package URL.
e.g. react
period
string
last-day, last-week, last-month or last-year. Default last-week.
last-daylast-weeklast-monthlast-year
default last-weeke.g. last-month
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

7 fields
dailyDailyCount[]
daystring
downloadsinteger (int64)
endstring
packagestring
startstring
totalinteger (int64)
curl "https://api.hoshime.com/v1/npm/downloads?name=react&period=last-month" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": {
    "daily": [
      {
        "day": "2026-10-07",
        "downloads": 35968597
      },
      {
        "day": "2026-10-08",
        "downloads": 37575226
      }
    ],
    "end": "2026-11-05",
    "package": "react",
    "start": "2026-10-07",
    "total": 806498133
  },
  "meta": {
    "cached": false,
    "endpoint": "downloads",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

maintainerPackages

GET/v1/npm/maintainerPackages

Packages one npm user maintains, as the registry search ranks them, 20 per page.

scope social:read1 unitcached 30 minpaginated

Parameters

username
string
required
npm username, such as sindresorhus.
e.g. sindresorhus
cursor
string
meta.pagination.nextCursor of the previous page. Omit it for the first page.
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

8 fields
descriptionstring
keywordsstring[]
namestring
publishedAtstring
publisherstring
scorenumber (double)
urlstring
versionstring
curl "https://api.hoshime.com/v1/npm/maintainerPackages?username=sindresorhus" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Real response
{
  "data": [
    {
      "description": "ANSI escape codes for styling strings in the terminal",
      "keywords": [
        "ansi",
        "styles"
      ],
      "name": "ansi-styles",
      "publishedAt": "2026-07-26T14:57:36Z",
      "publisher": "sindresorhus",
      "score": 84.03785,
      "url": "https://www.npmjs.com/package/ansi-styles",
      "version": "7.0.0"
    },
    {
      "description": "Get the visual width of a string - the number of columns required to display it",
      "keywords": [
        "string",
        "character"
      ],
      "name": "string-width",
      "publishedAt": "2026-09-24T14:37:52Z",
      "publisher": "sindresorhus",
      "score": 83.01636,
      "url": "https://www.npmjs.com/package/string-width",
      "version": "8.3.0"
    }
  ],
  "meta": {
    "cached": false,
    "endpoint": "maintainerPackages",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "pagination": {
      "nextCursor": "EpcDEgV…",
      "hasMore": true,
      "total": null
    },
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}

orgPackages

GET/v1/npm/orgPackages

Packages of one npm organization (scope such as @sveltejs), sorted by name, 100 per page.

scope social:read1 unitcached 30 minpaginated

Parameters

org
string
required
npm organization name without the @, such as sveltejs or types.
e.g. sveltejs
limit
integer
Items per page, 1 to 500.
default 100
cursor
string
meta.pagination.nextCursor of the previous page. Omit it for the first page.
tunnel
string
Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy.
proxy
string
Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it.
profileId
string
Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only.

Response data

2 fields
namestring
urlstring
curl "https://api.hoshime.com/v1/npm/orgPackages?org=sveltejs" \
  -H "Authorization: Bearer $HOSHIME_TOKEN"
200 Response shape
{
  "data": [
    {
      "name": "…",
      "url": "https://…"
    }
  ],
  "meta": {
    "cached": false,
    "endpoint": "orgPackages",
    "fetchedAt": "2026-11-06T09:41:00Z",
    "pagination": {
      "nextCursor": "EpcDEgV…",
      "hasMore": true,
      "total": null
    },
    "platform": "npm",
    "requestId": "req_2Xb9kQ…",
    "units": 1
  }
}
esc
↑↓ move↵ open