Skip to main content

API Keys

All CAS Parser API requests require authentication via the x-api-key header.

Getting Your API Key

From the dashboard

  1. Sign up at app.casparser.in
  2. Navigate to DevelopersAPI Keys
  3. Click Generate API Key
  4. Copy and store securely

From a coding agent (automated)

If you’re using a coding agent (Claude Code, Cursor, etc.), it can obtain an API key for you automatically. The agent generates a one-time URL, you open it in your browser and approve, and the agent receives the key — no copy-paste needed.
See the API reference for full details on the agent auth endpoints.
Never expose your API key in client-side code. Use access tokens for frontend applications.

Using API Keys

Access Tokens

For frontend/SDK applications, use short-lived access tokens instead of exposing your API key.

Token Flow

Generate Access Token

Backend (server-side):
Frontend (client-side):

Token Properties

Verify Token

Security Best Practices

1. Environment Variables

Never hardcode API keys:

2. Backend Token Generation

Create a backend endpoint:

3. Rate Limiting

Implement rate limiting on your backend:

4. HTTPS Only

Always use HTTPS for API requests. The API will reject HTTP requests.

5. Key Rotation

Rotate API keys periodically:
  1. Generate new API key in dashboard
  2. Update environment variables
  3. Deploy updated code
  4. Delete old API key

Sandbox Key

For testing and development:
  • Returns sample data
  • No credit consumption
  • Rate limited to 10 requests/minute

Troubleshooting

Next Steps

Quickstart

Make your first API call

Error Handling

Handle authentication errors