Skip to content

Latest commit

 

History

History
41 lines (29 loc) · 674 Bytes

pdf.md

File metadata and controls

41 lines (29 loc) · 674 Bytes
description
Create pdf from url

PDF

{% hint style="warning" %} In local install, you should set SCREENSHOT_APIenv var or connect first {% endhint %}

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)