npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@robtex/sdk

v0.3.0

Published

Lightweight TypeScript SDK for the Robtex API — DNS, IP, AS, Bitcoin, and Lightning Network intelligence

Downloads

284

Readme

@robtex/sdk

Lightweight TypeScript SDK for the Robtex API. DNS, IP, AS, Bitcoin, and Lightning Network intelligence.

  • Zero dependencies
  • Full TypeScript types
  • Works everywhere: Node, Deno, Bun, Cloudflare Workers, browsers
  • 55 endpoints covering DNS, passive DNS, IP reputation, geolocation, BGP, domain analysis, Bitcoin, and Lightning Network

Install

npm install @robtex/sdk

Quick Start

import { Robtex } from '@robtex/sdk';

const api = new Robtex();

// DNS lookup
const dns = await api.lookupDns({ hostname: 'google.com' });

// IP reputation — check against 100+ blocklists
const rep = await api.ipReputation({ ip: '8.8.8.8' });

// Passive DNS — find all records for a domain
const pdns = await api.pdnsForward({ domain: 'example.com' });

// Bitcoin address lookup
const addr = await api.lookupBitcoinAddress({ address: '1A1zP1eP5QGefi2DMPTfTL5SLmv7DivfNa' });

Authentication (Optional)

Works without any key (rate-limited to 10 req/hr). Three options for higher limits:

// Free — no key, 10 req/hr
const api = new Robtex();

// Pro API key — higher limits
const api = new Robtex({ apiKey: 'your-key' });

// RapidAPI key — managed billing, plans from $19/mo
const api = new Robtex({ rapidApiKey: 'your-rapidapi-key' });

Get a RapidAPI key at https://rapidapi.com/robtex/api/robtex

Multi-step Investigation Example

import { Robtex } from '@robtex/sdk';

const api = new Robtex();

// Investigate a domain: DNS + IP reputation + shared hosting
const dns = await api.lookupDns({ hostname: 'suspicious-site.com' });
const ip = dns.records.find(r => r.type === 'A')?.value;

if (ip) {
  const [reputation, shared, geo] = await Promise.all([
    api.ipReputation({ ip }),
    api.domainSharedIp({ hostname: 'suspicious-site.com' }),
    api.ipGeolocation({ ip }),
  ]);
  console.log({ dns, ip, reputation, shared, geo });
}

All Methods

DNS

| Method | Description | |--------|-------------| | lookupDns({ hostname }) | All DNS records for a hostname | | dnsA({ hostname }) | A records | | dnsAAAA({ hostname }) | AAAA records | | dnsMx({ hostname }) | MX records | | dnsNs({ hostname }) | NS records | | dnsTxt({ hostname }) | TXT records | | dnsCname({ hostname }) | CNAME records | | dnsSoa({ hostname }) | SOA record | | dnsPtr({ ip }) | PTR record for an IP |

Reverse DNS

| Method | Description | |--------|-------------| | reverseLookupDnsRecords({ value, type?, limit?, offset? }) | Hostnames using a DNS value | | reverseLookupIp({ ip, limit?, offset? }) | Hostnames pointing to an IP | | reverseLookupMx({ mx, limit?, offset? }) | Hostnames using a mail server | | reverseLookupNs({ nameserver, limit?, offset? }) | Hostnames using a nameserver | | reverseLookupCname({ target, limit?, offset? }) | Hostnames CNAMEd to a target |

Historic Reverse DNS

| Method | Description | |--------|-------------| | historicReverseLookupIp({ ip, limit?, offset? }) | Previously pointed to an IP | | historicReverseLookupNs({ nameserver, limit?, offset? }) | Previously used a nameserver | | historicReverseLookupMx({ mx, limit?, offset? }) | Previously used a mail server | | historicReverseLookupCname({ target, limit?, offset? }) | Previously CNAMEd to a target |

Passive DNS

| Method | Description | |--------|-------------| | pdnsForward({ domain }) | Domain to DNS records (returns array) | | pdnsReverse({ value, type? }) | Value to domains (returns array) | | pdnsReverseHistoric({ value, type? }) | Historic reverse pDNS (returns array) |

IP Intelligence

| Method | Description | |--------|-------------| | ipReputation({ ip }) | Check against 100+ blocklists | | ipGeolocation({ ip }) | Country, city, coordinates | | ipNetwork({ ip }) | BGP route, ASN | | ipToAsn({ ip }) | Map IP to AS number | | ipBlocklistCheck({ ip }) | Threat intel blocklists (FireHOL, IPsum) | | ipThreatIntel({ ip }) | AbuseIPDB, CIRCL BGP ranking |

Legacy IP/AS

| Method | Description | |--------|-------------| | ipquery({ ip }) | Classic IP query (DNS + geo + network) | | asquery({ asn }) | Networks for an AS number |

AS / Routing

| Method | Description | |--------|-------------| | asInfo({ asn }) | AS name and organization | | asPrefixes({ asn }) | Announced BGP prefixes | | lookupAsWhois({ asn }) | AS WHOIS information |

Domain Analysis

| Method | Description | |--------|-------------| | domainReputation({ hostname }) | Reputation and threat data | | domainRanking({ hostname }) | Popularity (Tranco, Majestic, Umbrella, CrUX) | | domainBlocklistCheck({ hostname }) | DNS blocklist check | | domainSharedIp({ hostname, limit? }) | Domains on same IP | | domainSharedNs({ hostname, limit? }) | Domains with same nameservers | | domainSharedMx({ hostname, limit? }) | Domains with same mail server |

Hostname Utilities

| Method | Description | |--------|-------------| | parseHostname({ hostname }) | Parse into eTLD, domain, subdomain | | isSubdomain({ hostname }) | Check if subdomain | | registeredDomain({ hostname }) | Extract registered domain | | tldInfo({ tld }) | TLD information |

Lightning Network

| Method | Description | |--------|-------------| | lookupLightningNode({ pubkey }) | Node info by public key | | lookupLightningChannel({ short_channel_id }) | Channel info | | lookupLightningChannelsPerNode({ pubkey, limit?, offset? }) | Channels for a node | | getRecommendedLightningPeers({ pubkey, count? }) | Peer recommendations | | searchLightningNodesByAlias({ alias, limit? }) | Search nodes by name | | latestLightningChannels({ count? }) | Recently opened channels |

Bitcoin

| Method | Description | |--------|-------------| | lookupBitcoinTransaction({ txid }) | Transaction details | | lookupBitcoinAddress({ address }) | Address info and balance | | lookupBitcoinBlock({ height }) | Block details | | bitcoinAddressTransactions({ address, limit?, offset? }) | Transaction history | | bitcoinTransactionSpends({ txid }) | Spending transactions | | bitcoinBlockchainStats({ start_height, end_height }) | Block range statistics |

Utility

| Method | Description | |--------|-------------| | lookupMac({ mac }) | MAC address vendor (IEEE OUI) | | checkEmail({ email }) | Email verification via SMTP | | ping() | API health check |

Generic Call

For any endpoint, including future ones:

const result = await api.call('some_endpoint', { param1: 'value' });

Error Handling

import { Robtex, RobtexError } from '@robtex/sdk';

const api = new Robtex();
try {
  await api.ipReputation({ ip: '8.8.8.8' });
} catch (e) {
  if (e instanceof RobtexError && e.status === 429) {
    console.log(`Rate limited. Retry after ${e.retryAfter}s`);
  }
}

Custom Fetch

Pass your own fetch for proxies, logging, or testing:

const api = new Robtex({
  fetch: (url, init) => {
    console.log('Fetching:', url);
    return globalThis.fetch(url, init);
  },
});

Links

License

MIT