Developer API

Integrate RedactAI into Your App

Add intelligent document redaction to your application with our simple REST API

Quick Start
Get started with RedactAI API in minutes

1. Get your API key

redact_sk_1234567890abcdef

2. Upload and redact

curl -X POST https://api.redactai.com/v1/redact \
  -H "Authorization: Bearer redact_sk_1234567890abcdef" \
  -H "Content-Type: multipart/form-data" \
  -F "file=@document.pdf" \
  -F "redact_types=names,addresses"

3. Get the result

{
  "status": "completed",
  "file_id": "file_abc123",
  "redacted_url": "https://api.redactai.com/files/abc123_redacted.pdf",
  "redactions": {
    "names": 3,
    "addresses": 2
  }
}
API Endpoints
Complete API reference for RedactAI
POST
/api/redact

Upload a file and specify what to redact

Parameters (FormData)
fileFileDocument to redact
user_idstringUser identifier
redaction_typesstringComma-separated list
ai_instructionstringNatural language instruction (optional)
Response
{
  "success": true,
  "job_id": "uuid",
  "redaction_summary": "Found and redacted 3 names, 2 addresses",
  "redactions_count": 5,
  "redacted_file_url": "path/to/redacted/file",
  "original_file_url": "path/to/original/file"
}
GET
/api/status/[jobId]

Check the processing status of your redaction job

Response
{
  "id": "job-uuid",
  "status": "completed",
  "original_filename": "document.pdf",
  "redactions_count": 5,
  "processing_time": 2500,
  "original_file_url": "signed-url-to-original",
  "redacted_file_url": "signed-url-to-redacted",
  "created_at": "2024-01-01T00:00:00Z",
  "updated_at": "2024-01-01T00:00:30Z"
}
POST
/v1/ai-redact

Use natural language to describe what to redact

Parameters
filefileDocument to redact
instructionstringNatural language instruction
Example Request
curl -X POST /api/redact \
  -F "file=@document.pdf" \
  -F "user_id=user-uuid" \
  -F "redaction_types=names,addresses" \
  -F "ai_instruction=Redact all client information but keep technical details"
SDKs & Libraries
Official SDKs for popular programming languages

JavaScript/Node.js

npm install @redactai/node

Python

pip install redactai

JavaScript Example

import { RedactAI } from '@redactai/node';

const redact = new RedactAI('redact_sk_1234567890abcdef');

const result = await redact.redactFile({
  file: './document.pdf',
  redactTypes: ['names', 'addresses']
});

console.log(result.redactedUrl);
Your API Key
redact_sk_1234567890abcdef

Keep your API key secure and don't share it publicly.

Rate Limits
Requests per minute60
Files per hour100
Max file size10MB
Use Cases

Legal Documents

Redact sensitive client information

Survey Plats

Remove owner details, keep technical data

SaaS Integration

Add redaction to your platform

Need Help?