Basic request
curl https://kymaapi.com/v1/chat/completions \
-H "Authorization: Bearer kyma-your-api-key" \
-H "Content-Type: application/json" \
-d '{
"model": "llama-3.3-70b",
"messages": [{"role": "user", "content": "Hello!"}]
}'
With system prompt
curl https://kymaapi.com/v1/chat/completions \
-H "Authorization: Bearer kyma-your-api-key" \
-H "Content-Type: application/json" \
-d '{
"model": "llama-3.3-70b",
"messages": [
{"role": "system", "content": "You are a pirate."},
{"role": "user", "content": "Tell me about the weather."}
]
}'
Streaming
curl https://kymaapi.com/v1/chat/completions \
-H "Authorization: Bearer kyma-your-api-key" \
-H "Content-Type: application/json" \
-d '{
"model": "llama-3.3-70b",
"messages": [{"role": "user", "content": "Write a poem"}],
"stream": true
}'
List models
curl https://kymaapi.com/v1/models
Check rate limits
curl https://kymaapi.com/v1/auth/limits \
-H "Authorization: Bearer kyma-your-api-key"