SDKs
JavaScript SDK
Official JavaScript SDK for Node.js and browsers
JavaScript SDK
The JavaScript SDK uses the same package as the TypeScript SDK. For complete documentation, installation instructions, and examples, see the TypeScript SDK documentation.
Source code: GitHub | Package: @allscreenshots/sdk
Installation
npm install @allscreenshots/sdkQuick start
import { AllscreenshotsClient } from '@allscreenshots/sdk';
import fs from 'fs';
const client = new AllscreenshotsClient();
const imageBuffer = await client.screenshot({
url: 'https://github.com',
device: 'Desktop HD',
fullPage: true
});
fs.writeFileSync('screenshot.png', imageBuffer);Full documentation
For complete API documentation, configuration options, and advanced examples, see the TypeScript SDK documentation.
The SDK works identically in JavaScript and TypeScript projects - TypeScript users benefit from full type definitions and IntelliSense support.