Prerequisites
- cURL installed
- Get an API key
- Have a CAS PDF ready (or use sandbox key)
1. Parse a CAS PDF
2. Parse from URL
3. Try it yourself
Test without consuming credits:Check your credits
Response headers
Every API response includes:| Header | Description |
|---|---|
X-Request-ID | Unique request ID (e.g., req_abc123) for support |
X-Credits-Used | Credits consumed by this request |
X-Credits-Remaining | Remaining credits for billing period |
Error handling
Common errors
| Status | Error | Solution |
|---|---|---|
| 400 | Invalid password | Check PAN format (encrypted PAN for CDSL/NSDL) |
| 401 | Invalid API key | Verify your API key at app.casparser.in |
| 402 | Insufficient credits | Upgrade plan or wait for reset |
| 422 | Invalid PDF | Ensure PDF is not scanned/tampered |

