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

@skyscout/skyview-client

v1.1.0

Published

Fully-typed TypeScript client for NASA Goddard SkyView image service, generating public-domain survey cutouts (2MASS, DSS, WISE, GALEX, SDSS)

Readme

@skyscout/skyview-client

npm version License: BSD-3-Clause Public Domain Imagery

TypeScript client for NASA Goddard Space Flight Center's SkyView Image Service.

SkyView generates astronomical image cutouts across 100+ space mission and ground-based surveys, including 2MASS (Infrared), WISE (Mid-Infrared), DSS/DSS2 (Optical), GALEX (Ultraviolet), SDSS, and Fermi (Gamma-Ray).


🌟 Features

  • Direct Image URLs: Instant URL generation for <img src="...">, CSS backgrounds, or HTML5 Canvas drawImage() without server-side buffering.
  • 100% NASA Public Domain: Images produced by NASA SkyView are works of the U.S. Federal Government under 17 U.S.C. § 105 and are in the Public Domain, making them unencumbered for commercial prints, museum posters, and web applications.
  • Multiple Survey Bands: Near-IR (2MASS J, H, K, Color), Mid-IR (WISE 3.4µm, 4.6µm, 12µm, 22µm), Optical (DSS2 Color, Red, Blue, SDSS), UV (GALEX).
  • Zero Heavy Dependencies: Pure TypeScript built with standard fetch and AbortController.
  • Dual ESM & CommonJS: Full TypeScript declaration maps (.d.ts).

📦 Installation

npm install @skyscout/skyview-client

🚀 Quick Start

1. Direct Image URL (Zero Network Latency)

import { SkyviewClient } from '@skyscout/skyview-client';

const skyview = new SkyviewClient();

// Get an immediate 2MASS infrared cutout URL
const imageUrl = skyview.getImageUrl({
  position: { ra: 56.75, dec: 24.12 }, // Pleiades (M45)
  survey: '2MASS Color',
  pixels: 1000,
  sizeDeg: 1.5,
});

console.log(imageUrl);
// https://skyview.gsfc.nasa.gov/current/cgi/runquery.pl?Position=56.750000%2C+24.120000&Survey=2MASS+Color&Pixels=1000&Size=1.5&Return=JPEG

2. Fetch Image Blob for Canvas or Download

const blob = await skyview.fetchImageBlob({
  position: 'NGC 6231',
  survey: 'DSS2 Color',
  pixels: 1200,
  sizeDeg: 0.8,
});

// Create object URL for rendering in an HTML5 canvas or 300 DPI poster
const objectUrl = URL.createObjectURL(blob);

3. Fetch Raw FITS File

const fitsBuffer = await skyview.fetchFits({
  position: { ra: 88.07, dec: 32.55 },
  survey: '2MASS-K',
  pixels: 500,
  sizeDeg: 0.5,
});

🛰️ Common Surveys

| Survey Key | Waveband | Description | |---|---|---| | '2MASS Color' | Near-Infrared | False-color RGB composite from 2MASS J, H, and Ks bands | | '2MASS-J', '2MASS-H', '2MASS-K' | Near-Infrared | Individual 2MASS infrared bands | | 'DSS2 Color' | Optical | Digitized Sky Survey color optical plates | | 'DSS2 Red', 'DSS2 Blue' | Optical | High-resolution optical photographic survey | | 'AllWISE Color' | Mid-Infrared | Wide-field Infrared Survey Explorer color composite | | 'WISE 3.4', 'WISE 12' | Mid-Infrared | Thermal dust and cool stellar emission | | 'GALEX Near UV' | Ultraviolet | Galaxy Evolution Explorer UV star-forming regions | | 'SDSSg', 'SDSSr', 'SDSSi' | Optical | Sloan Digital Sky Survey multiband photometry |


⚖️ Licensing & Attribution

  • Code: Licensed under the open-source BSD-3-Clause License.
  • Imagery: Under United States law (17 U.S.C. § 105), works created by the U.S. Federal Government (including NASA) are in the Public Domain.
  • Commercial Use: NASA public-domain imagery may be used freely for commercial purposes, including art prints, physical posters, educational products, and digital media, without royalty or permission fees.

Attribution Helper

console.log(skyview.getAttribution('2MASS Color'));
// "Image courtesy of NASA / IPAC / 2MASS (U.S. Public Domain)."

🤝 Part of SkyScout

Developed by the SkyScout astronomy team.