PDF

Create pdf from url

In local install, you should set SCREENSHOT_APIenv var or connect first

Get

import naas_drivers
url = "https://google.com"
filename = "google.pdf"
naas_drivers.pdf.connect().get(url=url, filename=filename)

Get from Html

import naas_drivers
html = '<a src="https://google.com">test</a>'
filename = "google.pdf"
naas_drivers.pdf.connect().get(html=html, filename=filename)

Connect

import naas_drivers
pdf = naas_drivers.pdf.connect()
url = "https://google.com"
filename = "google.pdf"
pdf.get(url=url, filename=filename)