A JavaScript (and TypeScript) SDK for the ScreenshotOne.com API to take screenshots of any URL

Overview

jssdk

Build NPM package

An official Screenshot API client for JavaScript and TypeScript.

It takes minutes to start taking screenshots. Just sign up to get access and secret keys, import the client, and you are ready to go.

The SDK client is synchronized with the latest screenshot API options.

Installation

npm install screenshotone-api-sdk --save

Usage

Generate a screenshot URL without executing the request. Or download the screenshot. It is up to you:

import * as fs from 'fs';
import * as screenshotone from 'screenshotone-api-sdk';

// create API client 
const client = new screenshotone.Client("<access key>", "<secret key>");

// set up options
const options = screenshotone.TakeOptions
    .url("https://example.com")
    .delay(3)
    .blockAds(true);    

// generate URL 
const url = client.generateTakeURL(options);
console.log(url);
// expected output: https://api.screenshotone.com/take?url=https%3A%2F%2Fexample.com&delay=3&block_ads=true&access_key=%3Caccess+key%3E&signature=7f3419ece2c53ed2c7923c7d5deef290d662c3643822bf69ec8259ce10b3ea61

// or download the screenshot
const imageBlob = await client.take(options);
const buffer = Buffer.from(await imageBlob.arrayBuffer());
fs.writeFileSync("example.png", buffer)
// the screenshot is store in the example.png file

License

screenshotone/jssdk is released under the MIT license.

You might also like...

Screenshots with JavaScript

html2canvas Homepage | Downloads | Questions JavaScript HTML renderer The script allows you to take "screenshots" of webpages or parts of it, directly

Jan 4, 2023

Uma api para encurtador url com typescript e Clean architecture.

Lyck 🔗 🖇️ Esta e a parte de backend de um encurtador de link que estou a desevolver. tecnologias 🔧 🛠️ Express. Joi. Uuid. Module-alias. BcryptJs.

Jan 28, 2022

Open source app to beautify screenshots, quickly and easily

Codename: Pika What it does Lets you quickly beautify screenshots by adding rounded corners, background colors, shadows and more. You can copy the bea

Dec 29, 2022

When pasting screenshots into obsidian notes, convert the images to jpeg and compress them

When pasting screenshots into obsidian notes, convert the images to jpeg and compress them

obsidian-paste-png-to-jpeg This plugin is inspired by obsidian-paste-image-rename, obsidian-paste-image-rename can be used when inserting images renam

Nov 15, 2022

A utility for taking screenshots of websites.

Tortor ⚡️ This is a website that allows you take screenshots of other websites. Simply enter the URL and a screenshot will be taken and available for

Jan 10, 2022

An application to capture screenshots automatically of your screen!

 An application to capture screenshots automatically of your screen!

TASCA : The Automatic Screenshot Capturing Application An application to capture screenshots automatically of your screen! Report Bug · Request Featur

Jan 27, 2022

A simple but powerful tool to make your screenshots prettier.

A simple but powerful tool to make your screenshots prettier.

SnipSnap A simple but powerful tool to make your screenshots prettier. Motivation I built SnipSnap because I wasn't happy with the other options as th

Dec 16, 2022

AWS CDK stack for taking website screenshots (powered by Puppeteer)

CDK Screenshot (powered by Puppeteer) Made possible by the excellent Puppeteer. Install export AWS_PROFILE=myprofile export AWS_DEFAULT_REGION=us-east

Oct 23, 2022

This is a Tic Tac Toe game built with HTML, CSS, and JavaScript. It is a simple and fun game where two players take turns marking X and O on a 3x3 grid.

This is a Tic Tac Toe game built with HTML, CSS, and JavaScript. It is a simple and fun game where two players take turns marking X and O on a 3x3 grid.

Tic Tac Toe Game This is a Tic Tac Toe game built with HTML, CSS, and JavaScript. It is a simple and fun game where two players take turns marking X a

Mar 4, 2023
Owner
ScreenshotOne.com
Fast and reliable screenshot API built to handle millions of screenshots a month. Get started for free.
ScreenshotOne.com
aka Scaletor, take screenshots of a piece of a map and scale/compare with other parts of the map

scale-a-tron A quick-and-dirty map that lets you compare one area to another. Draw a shape around a region, zoom in to another place on the map, and c

Stamen Design 24 Nov 7, 2022
This tool uses native browser APIs to take screenshots of a given web page, tab, window, or the user's entire screen.

This tool uses native browser APIs to take screenshots of a given web page, tab, window, or the user's entire screen.

xataio 761 Jan 1, 2023
A server setup to take screenshots against the green screen in-game.

alt:V Clothing Green Screener Support on Patreon. Seriously. Ever want screenshots of every single clothing item in GTA:V? Well this is your repositor

null 13 Dec 26, 2022
Movehat is a TypeScript SDK for Move on Sui built on top of Sui's TypeScript SDK and our fork of Ian Macalinao's `move-ts`.

Movehat Movehat is a TypeScript SDK for Move on Sui built on top of Sui's TypeScript SDK and our fork of Ian Macalinao's move-ts. Movehat aspires to b

Pentagon 10 Sep 30, 2022
Grupprojekt för kurserna 'Javascript med Ramverk' och 'Agil Utveckling'

JavaScript-med-Ramverk-Laboration-3 Grupprojektet för kurserna Javascript med Ramverk och Agil Utveckling. Utvecklingsguide För information om hur utv

Svante Jonsson IT-Högskolan 3 May 18, 2022
Hemsida för personer i Sverige som kan och vill erbjuda boende till människor på flykt

Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

null 4 May 3, 2022
Kurs-repo för kursen Webbserver och Databaser

Webbserver och databaser This repository is meant for CME students to access exercises and codealongs that happen throughout the course. I hope you wi

null 14 Jan 3, 2023
Piccloud is a full-stack (Angular & Spring Boot) online image clipboard that lets you share images over the internet by generating a unique URL. Others can access the image via this URL.

Piccloud Piccloud is a full-stack application built with Angular & Spring Boot. It is an online image clipboard that lets you share images over the in

Olayinka Atobiloye 3 Dec 15, 2022
The iofod SDK provides developers with the ability to interact with the main iofod interface within the Web worker, enabling rapid development of iofod extensions through the SDK.

iofod-sdk English | 简体中文 The iofod SDK provides developers with the ability to interact with the main iofod interface within the Web worker, enabling

iofod, Inc. 47 Oct 17, 2022
Changd is a open source web monitoring application for monitoring visual site changes using screenshots, XPath's or API's.

Changd is a open source web monitoring application and a free alternative to ChangeTower.com, Hexowatch.com, and other SaaS-based solutions. Changd ca

Paul Aschmann 110 Jan 3, 2023