
Start Your AI Journey Today
- Access 100+ AI APIs in a single platform.
- Compare and deploy AI models effortlessly.
- Pay-as-you-go with no upfront fees.
Learn how to implement document redaction in Python using Eden AI's OCR anonymization API. Launch an async redaction job and retrieve results using two simple API calls to protect sensitive data.
Document redaction, or anonymization, is crucial in industries like healthcare, law, and finance where sensitive data must be protected.
With Eden AI’s asynchronous OCR anonymization API, you can automate this process using Python in just a few steps.
This tutorial walks you through how to redact documents using Eden AI’s API via Python, using a two-step asynchronous process.
Document redaction, also known as anonymization, is the process of hiding or removing sensitive information, such as names, dates, or identification numbers from documents.
This helps protect privacy and ensures compliance with data protection regulations by making confidential data unreadable or invisible.
1. Create an account: If you don't have an Eden AI account, create one for free using the following link. Then you can obtain your API key in the API Keys section, which you can use to access various AI services.
2. Access OCR Tools: Once logged in, go to the document parsing section of the platform.
3. Choose the Document Redaction Feature: Select the Document Redaction tool. You can also explore other OCR tools.
The process is asynchronous to allow for better performance and scalability. Redacting a document can take time depending on file size and complexity, so:
This two-step system is ideal for batch processing or workflows where real-time response isn’t required.
If you haven’t already, install the requests module which allows Python to send HTTP requests:
The first step is to initiate the redaction process by launching a job. You’ll need to send the image URL to the API for processing.
Once the job is launched, you need to fetch the results using the public_id.
In addition to launching and retrieving results from redaction jobs, Eden AI provides optional endpoints to help you manage your anonymization tasks more efficiently:
Eden AI provides several advantages.
You can choose between different AI services and providers, helping you compare results for the best performance.
Streamline development with one API key that gives access to multiple AI service. Skip the complexity of separate integrations and launch faster.
It’s a pay-as-you-go model—pay only for what you use. There are no upfront costs, offering flexible access to various AI services with just one API key.
With just a few lines of code, you can automate document redaction using Python and Eden AI.
The two-step process ensures accuracy and flexibility, especially for larger workloads.
Whether you’re processing legal files, patient records, or financial data, Eden AI provides a scalable and secure solution for anonymization.
Start redacting smarter, not harder, with Eden AI.
You can access the full documentation for Document Redaction here.
You can directly start building now. If you have any questions, feel free to chat with us!
Get startedContact sales