API access requires a Business or Enterprise plan. Startup and free trial accounts cannot call the REST API, even with a valid key.
What you can build
| Use case | Primary endpoints |
|---|---|
| Visibility dashboards | POST/GET /seo-site-report, /seo-site-report/history |
| Agency client reporting | Prefill, report, and history endpoints per workspace |
| Recommendation workflows | Report data + POST /improve-content-* |
| AI assistant integrations | POST /chat with useWorkspaceContext: true |
Plan eligibility
| Plan | API access | Monthly AI credits |
|---|---|---|
| Free trial | No | 10 |
| Startup | No | 300 |
| Business | Yes | 500 |
| Enterprise | Yes | Unlimited |
Base URL
/v1.
Authentication
Send your API key in theapi-key request header on every call:
krastie_ prefix, expire 30 days after generation, and are shown only once when created. Store them securely.
Create and manage keys
Key management uses your logged-in Krastie session (cookie auth), not the API key itself.| Method | Endpoint | Description |
|---|---|---|
GET | /v1/users/api-key | Key metadata (prefix, expiry, name). Does not return the secret. |
POST | /v1/users/generateApiKey | Create or rotate a key. Body: { "name": "My integration" } |
DELETE | /v1/users/api-key | Revoke the current key |
Usage and limits
- Each successful AI text or chat request consumes 1 AI credit from your monthly plan allowance.
- Visibility report refresh limits vary by plan. See the pricing page.
- Image generation increments image-generation usage separately.
- When credits are exhausted, endpoints return
403with a plan-specific limit message. - Usage resets monthly for paid plans.
o1, o3-mini, gpt-5, gpt-4.5) require a paid plan (Startup or above), not just API access.
Response headers
All/v1 routes include:
| Header | Value |
|---|---|
api-version | v1 |
deprecated | false |
Error format
Errors return JSON withmessage and usually errCode:
| Status | Meaning |
|---|---|
401 | Missing/invalid API key, expired key, or banned user |
403 | Plan not eligible, usage limit reached, or feature restricted |
404 | Resource not found (e.g. job ID) |
429 | Rate limit or refresh limit exceeded |
500 | Server error |
Supported models
Text and chat endpoints accept model IDs from supported providers:- OpenAI:
gpt-4o,gpt-4o-mini,gpt-4.1,o1,o3-mini, and related GPT-family IDs - Anthropic: Claude models (IDs containing
claude) - Google: Gemini models (IDs containing
gemini)
Quick start
- Upgrade to Business or Enterprise.
- Log in at app.krastie.ai and generate an API key under account settings.
- Run a visibility report:
API sections
AI visibility
Reports, prefill, history, and workspace context.
AI generation
Content generation, SEO scoring, and improvement.
Chat sessions
Assistant with visibility-aware workspace context.
Brand voice
Manage brand voices for consistent content.