App Logo
reduck.ai

Download PDF from a direct URL

Automatically download PDF from a direct URL on reduck.ai. Download a PDF from a direct, public link (for example an invoice PDF link that a list_invoices script returns) and return the saved file name with its path on your computer, or a download link when it runs on a managed browser. Links that only work in a signed-in vendor session need that vendor's own download script. A link that opens in the browser instead of downloading, on a site with no page of its own to fetch it from, fails with an error that says so.

Input

url required

Direct PDF URL (e.g. a pdfUrl from a list_invoices script).

filename optional

Preferred output filename. Honoured when the PDF is fetched in-page; a PDF the browser downloads natively keeps the name the server sends.

Output

filename required

The saved file name; it can end in " (2)" when a file of that name already exists.

url optional

A link to the saved file on a managed browser; null on the user's Chrome.

via optional

How the bytes were captured: "native-download" or "in-page-fetch".

path optional

The saved file on the machine that runs the browser (the user's Chrome); null on a managed browser.

sourceUrl optional

FAQ

Download a PDF from a direct, public link (for example an invoice PDF link that a list_invoices script returns) and return the saved file name with its path on your computer, or a download link when it runs on a managed browser. Links that only work in a signed-in vendor session need that vendor's own download script. A link that opens in the browser instead of downloading, on a site with no page of its own to fetch it from, fails with an error that says so.
Ask an AI agent connected to Reduck to run reduck/reduck.ai/download_pdf_url, or run it from a terminal with the Reduck CLI: npx @reduck-ai/cli@latest run --script reduck/reduck.ai/download_pdf_url
You do not need one. "Download PDF from a direct URL" drives the real reduck.ai pages in a browser, so it works whether or not reduck.ai offers an API for this.
Required: url. Optional: filename.
It returns url, via, path, filename, sourceUrl.
No. It only uses pages of reduck.ai that are reachable without signing in.
It only reads. It looks things up on reduck.ai and changes nothing there.
Ask an AI agent connected to Reduck to run reduck/reduck.ai/download_pdf_url, or run it from a terminal with the Reduck CLI: npx @reduck-ai/cli@latest run --script reduck/reduck.ai/download_pdf_url
It is part of Reduck's official curated catalogue.

Start building not clicking