Rasterwise

FREEMIUM
By whoisjuan
Updated 5 months ago
Video, Images
-/10
Popularity Score
-
Latency
-
Success Rate

Rasterwise API Documentation

Affordable and Accurate Screenshot Capture API with Email Workflows and Webhooks

View API Details
GETget-screenshot
GETget-screenshot

Handles all the requests to generate screenshots on demand.

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
Required Parameters
urlSTRING
REQUIREDURL of the website / page you want to screenshot. Should start with http:// or https://
Optional Parameters
customcssSTRING
OPTIONALA custom CSS style you want to inject before the capture. If passed we will inject the style declaration as a header <style> just before the capture operation.
customjsSTRING
OPTIONALA custom JS evaluation you want to inject before the capture. If passed we will inject this statement as a header <script> with a just in time model, after all the required operations and just before the capture operation. This is important to have in mind when passing JS that changes the rendering.
hidemsgBOOLEAN
OPTIONALIf set to true, we will hide message, chat and customer support clients. Currently hides the following clients: Intercom, Drift, Facebook and Tawk (partiallly).
widthNUMBER
OPTIONALWidth in pixels of the viewport when taking the page screenshot.
heightNUMBER
OPTIONALHeight in pixels of the viewport when taking the page screenshot.
fullpageBOOLEAN
OPTIONALIf set totrue, we will calculate the full height of the website and used it as the height in pixels of the viewport when taking the page screenshot. Any passed height value will be ignored.
formatSTRING
OPTIONALThe file type/format in which you want to get your capture. It can be either png or jpeg.
webhookSTRING
OPTIONALA valid endpoint url that can receive and respond to a POSTrequest (preferably an endpoint that you control). If set, we will send a POST request with the final response of the original call, to the provided endpoint (webhook listener). For your convenience we send the response in the body and queryStringParameters of the request.
highlightSTRING
OPTIONALA custom word or phrase you want to highlight. If passed, GetScreenshot will look for that string on the website and highlight all its instances with bright-yellow box.
emailSTRING
OPTIONALA valid email address. If set, we will send a formatted email to this email address including the capture image and the details of the capture (capture time and URL).
presetSTRING
OPTIONALIf set, we will control the dimension and user-agent to simulate the preset device or graphics display resolution. If a preset value is passed, we will ignore other passed dimension parameters. This parameter can accept any of the following presets: iphone 5 (iPhone 5) iphone678 (iPhone 6/7/8) iphone678_plus (iPhone 6/7/8 +) iphonex (iPhone X / XS) pixel2 (Google Pixel 2) pixel2_xl (Google Pixel 2 XL) ipad (iPad in Vertical) ipadpro (iPad Pro Vertical) hvga (320 x 480) wvga (480 x 800) dvga (640 x 960) wxga_v (768 x 1280) xga (1024 x 768) wxga_s (1280 x 800) wxga_l (1366 x 768) sxga (1280 x 1024) wsxga_plus (1680 x 1050)
hidecookieBOOLEAN
OPTIONALIf set to true, we will hide cookie disclaimers that will usually appear as floating boxes or fixed containers. The hiding is not guaranteed but it has a pretty broad coverage and the underlying hiding heuristic is updated weekly.
Code Snippet
unirest.get("https://whoisjuan-rasterwise-v1.p.rapidapi.com/get-screenshot?format=png")
.header("X-RapidAPI-Host", "whoisjuan-rasterwise-v1.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
Sample Response
General
Request URL: https://whoisjuan-rasterwise-v1.p.rapidapi.com/get-screenshot
Request Method: GET
Response Headers
Response Body

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.get("https://whoisjuan-rasterwise-v1.p.rapidapi.com/get-screenshot?format=png")
.header("X-RapidAPI-Host", "whoisjuan-rasterwise-v1.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication