Build with the
ClearSight API
REST API with structured JSON responses, verification scores, and page-level citations. Ship document intelligence in under a day.
Quick Start
Upload a document in 5 lines
Get your sandbox API key, install requests, and you are processing documents in under a minute.
import requests
response = requests.post(
"http://api.getclearsight.in/v1/documents/upload",
headers={"Authorization": "Bearer cs_live_xxxxx"},
files={"file": open("annual_report.pdf", "rb")},
data={"domain": "corporate_finance"}
)
print(response.json())API Reference
Key endpoints
/v1/documents/upload
Upload and process a document end-to-end
/v1/documents/{id}/extract
Retrieve extraction results with citations
/v1/ask
Semantic search with RAG synthesis
/v1/search
Vector similarity search across documents
/v1/auth/token
Authenticate and receive JWT access token
/v1/auth/refresh
Refresh an expired access token
/v1/auth/me
Get current authenticated user info
/v1/health
Service health check endpoint
Authentication
API Key + JWT dual system
Authenticate with your API key to receive a short-lived JWT access token (30-minute expiry). Use the JWT for all subsequent requests. Refresh tokens before expiry to maintain sessions.
API Keys
Prefixed with cs_live_ for production and cs_sandbox_ for sandbox. Generated on sign-up.
JWT Tokens
30-minute expiry. Include in Authorization header as Bearer token. Use /v1/auth/refresh to renew.
# 1. Get JWT token
curl -X POST http://api.getclearsight.in/v1/auth/token \
-H "Content-Type: application/json" \
-d '{
"api_key": "cs_live_xxxxx"
}'
# Response:
# {
# "access_token": "eyJhbG...",
# "token_type": "bearer",
# "expires_in": 1800
# }
# 2. Use token in requests
curl -X GET http://api.getclearsight.in/v1/documents \
-H "Authorization: Bearer eyJhbG..."Rate Limiting
Tier-based rate limits
Rate limits are enforced per API key using Redis-backed minute buckets. Exceeding limits returns HTTP 429 with a Retry-After header.
Sandbox
60 requests/minute
10 documents/day
Pro
300 requests/minute
Unlimited
Enterprise
Custom
Unlimited
SDKs & Tools
Everything you need to integrate
Postman Collection
Pre-configured collection with all endpoints, environments, and example requests.
OpenAPI Spec
Full OpenAPI 3.1 specification. Generate client SDKs in any language.
Swagger UI
Interactive API documentation at api.getclearsight.in/docs
Get your sandbox API key
15-day free trial. Full Tier 0 extraction. Pre-loaded sample documents. No credit card required.
Start Free Trial