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 🙏

© 2024 – Pkg Stats / Ryan Hefner

lightshot-gallery-downloader-cli

v1.0.3

Published

A small Node.JS program to download your LightShot(Prntscr.com) Gallery

Downloads

17

Readme

LighshotGalleryDownloaded-CLI

A small Node.JS program to download your LightShot(Prntscr.com) Gallery

Compatibility

Works on Linux/Windows/MacOS

Depedencies

Node.JS v12.16.2 or newer ( Prior versions haven't been tested. )

Usage

Prior to use this program you will need to download your gallery information into a target.json

To generate the target.json you can perform a cURL request like the one below Note: The file will be generated in the folder your terminal is currently in!

Edit the request with your own cookie

-H 'cookie: __auth=<YOUR COOKIES>'

Note: This request will only retrieve your last 10.000 screenshots.

Request

curl 'https://api.prntscr.com/v1/' \
  -H 'authority: api.prntscr.com' \
  -H 'pragma: no-cache' \
  -H 'cache-control: no-cache' \
  -H 'accept: application/json, text/javascript, */*; q=0.01' \
  -H 'user-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.102 Safari/537.36' \
  -H 'content-type: application/json' \
  -H 'origin: https://prntscr.com' \
  -H 'sec-fetch-site: same-site' \
  -H 'sec-fetch-mode: cors' \
  -H 'sec-fetch-dest: empty' \
  -H 'referer: https://prntscr.com/gallery.html' \
  -H 'accept-language: fr-CA,fr;q=0.9,fr-FR;q=0.8,en-US;q=0.7,en;q=0.6,it;q=0.5,ru;q=0.4' \
  -H 'cookie: __auth=<YOUR COOKIES>' \
  --data-binary '{"jsonrpc":"2.0","method":"get_user_screens","id":1,"params":{"count":10000}}' \
  --compressed > target.json

Once you have your target.json file, clone or download LighshotGalleryDownloaded-CLI.

git clone https://github.com/Wipie/LightShotGalleryDownloader-CLI.git

Then get into the root repository and open a terminal to install node depedencies.

npm install

After installating depedencies, move the target.json file into the root of the program your folder should look like this

.
├── node_modules                
├── images                      # Folder where downloaded image will output.
├── package-lock.json    
├── package.json        
├── index.js                    # LightshotGalleryDownloader-CLI
├── target.json                 # Your target.json
├── LICENSE
└── README.md

Finally in a terminal run the program

node .

Let it run depending on how much screenshots there is it might take a LONG time.

Troubleshooting

If during download you are getting error while downloading, navigate inside index.js and uncomment Line 18, wipe the /images/ folder and try again. It will take longer but you won't be timed out by prntscr.com