Image to PDF in Command Line

This page describes how to use our cloud-based API to convert images to PDF from the command line.

Sample Output

Installation

Install the application from PyPI
pip install pdfcrowd

We also offer other installation options.

Authentication

The credentials to access the API are your Pdfcrowd username and the API key.

User Manual

Refer to the Image to PDF Command Line Reference Manual for a description of all command line options.

Code Examples

Here are a few Command Line examples to get you started quickly with the API. See more examples.

image2pdf -user-name "your_username" -api-key "your_apikey" \
    "/path/to/logo.png" > "logo.pdf"
image2pdf -user-name "your_username" -api-key "your_apikey" \
    "https://pdfcrowd.com/static/images/logo.png" > "logo.pdf"

Troubleshooting

  • Refer to the API Status Codes page if the API returns an error.
  • You can use -debug-log to get detailed info about the conversion, such as load errors, load times, browser console output, etc.
  • Check the FAQ.
  • Contact us if you need help or missing a feature.