KardKit AI API
Integrate the wisdom of the ancients into your own creations. RESTful API with JSON responses.
Base URL
https://yourdomain.com/api/v1๐ Authentication
All API endpoints require authentication via an API key. Include your key in the Authorization header as a Bearer token.
http
POST /api/v1/chat Authorization: Bearer kk_your_api_key_here Content-Type: application/json
โ ๏ธ Security: Never expose your API key in client-side code. Always call the API from a secure server environment.
๐ค Available Models
| Model ID | Provider |
|---|---|
gpt-4 | OpenAI |
gpt-4o | OpenAI |
gemini | |
gemini-flash | |
claude | Anthropic |
claude-sonnet | Anthropic |
POST
/api/v1/chatSend messages to any supported AI model and receive a response.
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
model | string | Optional | Model ID. Options: gpt-4, gpt-4o, gemini, gemini-flash, claude, claude-sonnet. Default: gpt-4 |
messages | array | Required | Array of message objects with role (user|assistant|system) and content fields. |
Request
json
{
"model": "gpt-4",
"messages": [
{ "role": "user", "content": "Hello! Explain the Iliad in 3 sentences." }
]
}Response
json
{
"id": "kardkit-abc12345",
"object": "chat.completion",
"model": "gpt-4",
"choices": [
{
"message": {
"role": "assistant",
"content": "The Iliad is an ancient Greek epic poem..."
},
"finish_reason": "stop",
"index": 0
}
]
}POST
/api/v1/imagesGenerate images from text prompts using DALL-E 3.
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
prompt | string | Required | Text description of the image you want to generate. Be specific for best results. |
Request
json
{
"prompt": "A majestic owl perched on an ancient Greek column at sunset"
}Response
json
{
"images": ["https://cdn.openai.com/...image.png"],
"prompt": "A majestic owl...",
"model": "dall-e-3"
}โก Rate Limits
| Plan | Chat | Images | API Access |
|---|---|---|---|
| Free (Agora) | 20/day | 5/day | None |
| Scholar ($9.99/mo) | 150/day | 40/day | 1 key ยท 10K calls/mo |
| Oracle ($29.99/mo) | Unlimited | 150/day | 5 keys ยท 100K calls/mo |
โ ๏ธ Error Codes
200Success โ request was processed correctly400Bad Request โ missing or invalid parameters401Unauthorized โ invalid or missing API key403Forbidden โ your plan doesn't support this feature429Too Many Requests โ daily limit exceeded, upgrade your plan500Internal Server Error โ something went wrong on our end