Skip to content

skirk-mpr/HeadlessChromium.Puppeteer.Lambda.Dotnet

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

90 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HeadlessChromium.Puppeteer.Lambda.Dotnet

Packages everything you need to run PuppeteerSharp in AWS Lambda on Chromium into a Nuget Package

Build status CodeFactor Nuget status

Description

The chromium binary for this project has been extracted from the NPM project chrome-aws-lambda. It is automatically extracted to /tmp/chromium at runtime.

Usage

Screenshot a URL as a byte[]. This project requires lambda to be configured as netcoreapp3.1

var browserLauncher = new HeadlessChromiumPuppeterLauncher(logger);

using(var browser = await browserLauncher.LaunchAsync())
using(var page = await browser.NewPageAsync())
{
    await page.GoToAsync(url);
    return await page.ScreenshotDataAsync();
}

For more use cases see the PuppeteerSharp documentation

Projects using this library

These projects are using this library and are good examples of how you might consume this nuget package

Building

To build locally:

.\build.ps1 -Target Build

About

Packages everything you need to run PuppeteerSharp in AWS Lambda on Chromium

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 78.9%
  • PowerShell 21.1%