Skip to main content

Protect Document - Password Encryption API

PDF4me Protect Document is a powerful enterprise-grade solution that secures PDF files with password protection through advanced API integration. This comprehensive document security service efficiently processes PDF files, providing robust password protection, flexible permission control, and advanced encryption capabilities for enhanced document security and access control. The API processes document protection by receiving source PDF documents through REST API calls, utilizing advanced encryption technology and intelligent security algorithms for accurate password protection and professional document security management. With comprehensive support for password protection, permission control, and professional document security, this solution is ideal for document security, access control, automated protection, and enterprise document workflows that require reliable PDF protection with guaranteed security and consistent output quality. Protect PDF documents easily with API for advanced document security and password protection.

Authenticating Your API Request

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

Key Features

  • Password Protection: Secure PDF files with strong password encryption
  • Permission Control: Set granular permissions for document access and usage
  • Document Security: Comprehensive PDF security and access control
  • Professional Encryption: High-quality document encryption and protection
  • Flexible Options: Support for various PDF formats and security levels
  • Advanced Security: Detailed permission management and access control
  • Seamless API Integration: RESTful API designed for automated document processing workflows and enterprise system integration

REST API Endpoint

The PDF4me REST API uses standard HTTP methods to interact with resources. All document protection operations are performed through a single endpoint:

  • Method: POST
  • Endpoint: /api/v2/Protect

Supported PDF Protection Features

The API provides comprehensive support for various PDF protection and security capabilities:

Password Protection

  • Document Encryption: Secure PDF files with password-based encryption
  • Access Control: Control document access with password authentication
  • Security Management: Comprehensive PDF security and protection
  • Professional Encryption: High-quality document encryption and security
  • Advanced Processing: Support for complex security requirements

Permission Control

  • Granular Permissions: Set specific permissions for document usage
  • Access Management: Control printing, copying, and modification rights
  • Professional Control: High-quality permission management and control
  • Flexible Options: Customizable security parameters for specific requirements

Document Security

  • Comprehensive Protection: Advanced PDF security and access control
  • Professional Security: High-quality document protection and encryption
  • Advanced Management: Support for various security scenarios
  • Enterprise Integration: Professional-grade document security solutions

REST API Parameters

Complete list of parameters for the Protect Document REST API. Parameters are organized by category for better understanding and implementation.

Important: Parameters marked with an asterisk (*) are required and must be provided for the API to function correctly.

Required Parameters

ParameterTypeDescriptionExample
File Content*Base64The complete content of the PDF document encoded in Base64 format for password protection and security operations. This parameter contains the entire PDF file data required for document encryption, password protection, and security management workflows. Essential for secure document processing and API-based PDF protection operations.JVBERi...
File Name*StringThe source PDF document filename with proper .pdf extension for password protection and security operations. This parameter identifies the input document for PDF protection processing, encryption, and security management workflows. Required for document identification and processing pipeline management in PDF protection operations.document.pdf
Password*StringThe password for PDF file protection and encryption operations. This parameter sets the password required to access the protected PDF document. The input must be in string format and will be used for document encryption and access control. Essential for PDF security and password-based protection.1234
PDF Permission*EnumSelect the permissions to be set while protecting the PDF with password. Choose from All (all permissions), None (no permissions), Copy (copy permission), Annotate (annotation permission), Fill Forms (form filling permission), Support Disabilities (accessibility support), Assemble (document assembly), or Digital Print (digital printing). This parameter controls user access rights and document usage permissions.All

Output

The PDF4me Protect Document REST API returns a response that can be viewed in multiple formats. Choose the view that best fits your needs:

JSON Response Format

The raw JSON response from the API:

{
"File Content": "Password protected PDF file content from PDF4me protect action",
"File Name": "Output file name from PDF4me protect action"
}

Request Example

Content-Type: application/json
Authorization: YOUR_API_KEY

Note: Get your API key from the PDF4me Dashboard

Payload

{
"docContent": "Please put PDF base64 content",
"docName": "output.pdf",
"password": "1234",
"pdfPermission": "All"
}

Code Samples

The PDF4me Protect Document REST API provides code samples in multiple programming languages. Choose the language that best fits your development environment:

C# (CSharp) Sample

Complete C# implementation for PDF protection:

PDF Protection Features

Password Protection

  • Document Encryption: Secure PDF files with password-based encryption
  • Access Control: Control document access with password authentication
  • Security Management: Comprehensive PDF security and protection
  • Professional Encryption: High-quality document encryption and security
  • Advanced Processing: Support for complex security requirements

Permission Control

  • Granular Permissions: Set specific permissions for document usage
  • Access Management: Control printing, copying, and modification rights
  • Professional Control: High-quality permission management and control
  • Flexible Options: Customizable security parameters for specific requirements

Document Security

  • Comprehensive Protection: Advanced PDF security and access control
  • Professional Security: High-quality document protection and encryption
  • Advanced Management: Support for various security scenarios
  • Enterprise Integration: Professional-grade document security solutions

Industry Use Cases & Applications

Use Cases

  • Document Security: Protect sensitive PDF documents with password encryption
  • Access Control: Control document access and usage permissions
  • Compliance Management: Meet security requirements and compliance standards
  • Document Protection: Secure PDF files from unauthorized access
  • Workflow Security: Integrate PDF protection into automated workflows
  • Enterprise Security: Professional-grade document security solutions
  • Document Management: Comprehensive PDF security and protection
  • Business Process Automation: Automate PDF protection workflows for enterprise operations

Get Help