API V2

PDF4me API Documentation

The PDF4me V2 API provides powerful document processing capabilities with enhanced features and improved performance. This guide will help you get started with integrating the V2 API into your applications.

This section introduces the fundamental concepts for working with the PDF4me API, covering authentication methods, response codes, and example code snippets.

API Reference

The PDF4me Web API is crafted for simplicity and seamless integration. To safeguard your data’s security and privacy, all communications are strictly conducted over HTTPS. Unsecured HTTP connections are not permitted.


Base URL

All requests contain the following base URL:

https://api.pdf4me.com


Authenticating Your API Request

To access the PDF4me Web API, every request must include proper authentication credentials. Authentication ensures secure communication and validates your identity as an authorized user.

Getting Your API Key

We assume you already have an account with us and a PDF4me API Key. If you don’t have one, create an account with us for getting an API Key. You can refer to the documentation on getting started with PDF4me for help with the process.

Request Headers

Authorization: [Your API Key from PDF4me]
Content-Type: application/json

Example Request

curl -X POST https://api.pdf4me.com/v2/convert \
  -H "Authorization: YOUR_API_KEY_HERE" \
  -H "Content-Type: application/json" \
  -d '{"operation": "convert", "format": "pdf"}'

Authenticating Your API Request

To access the PDF4me Web API, every request must include proper authentication credentials. Authentication ensures secure communication and validates your identity as an authorized user.

Header

Authorization: Apikey from pdf4me
Content-Type: application/json

PDF4me API key dashboard interface

Key Features of V2 API

Enhanced Performance

  • Faster processing times
  • Improved error handling
  • Better response formats

Advanced Document Operations

  • Convert Documents: Transform various file formats to PDF and vice versa
  • Merge & Split: Combine multiple PDFs or split them into separate files
  • OCR Processing: Extract text from scanned documents
  • Digital Signatures: Add secure digital signatures to your documents
  • Form Processing: Fill PDF forms programmatically
  • Watermarking: Add text or image watermarks
  • Compression: Optimize PDF file sizes

Security & Compliance

  • HTTPS-only communication
  • Secure API key authentication
  • Data privacy protection
  • GDPR compliant processing

Response Codes

The API returns standard HTTP status codes to indicate success or failure:

  • 200 OK: Request successful
  • 400 Bad Request: Invalid request parameters
  • 401 Unauthorized: Invalid or missing API key
  • 403 Forbidden: Insufficient permissions
  • 404 Not Found: Endpoint not found
  • 429 Too Many Requests: Rate limit exceeded
  • 500 Internal Server Error: Server error occurred

PDF4me API Samples

Ready to start coding? We’ve prepared a comprehensive collection of code samples and examples to help you integrate PDF4me API quickly and efficiently.

Our GitHub repository contains ready-to-use examples in multiple programming languages for all PDF4me API features:

🔧 Supported Languages:

  • C# (.NET 6/8)
  • Java (8/11/21+)
  • Python (3.7+)
  • JavaScript (Node.js 14+)
  • Salesforce (Apex)

📁 Sample Categories:

  • Barcode - Create, read, and manipulate barcodes
  • Convert - File format conversions (PDF ↔ Word/Excel/PowerPoint/HTML/Images)
  • Edit - Add stamps, attachments, signatures
  • Extract - Extract text, tables, attachments, resources
  • Security - Protect and unlock PDFs
  • Merge & Split - Combine or separate PDF documents
  • Forms - PDF form field operations
  • Generate - Document generation and Swiss QR bills
  • Optimize - PDF compression and optimization

🚀 Quick Start:

  1. Clone the repository
  2. Get your API key from the dashboard
  3. Choose your preferred language sample
  4. Follow the README instructions
  5. Replace the API key placeholder and run!

Next Steps

  1. Explore the API Documentation: Visit the full API documentation for detailed endpoint references
  2. Try the Interactive Examples: Test API calls directly in your browser
  3. Join the Community: Get support and share experiences with other developers
  4. Check Rate Limits: Understand your account’s usage limits and upgrade options