Quickstart
Get up and running with the Kanva API in minutes.
Prerequisites
- A Kanva account with an active project
- An API key (see Authentication)
- Python 3.8+ or your preferred programming language
Making Your First API Call
Here's a simple example using Python:
import requests
API_URL = "https://kanva.human-driven.ai/api/v1"
API_KEY = "your_api_key_here"
PROJECT_ID = "your_project_id"
response = requests.post(
f"{API_URL}/projects/{PROJECT_ID}/predict",
headers={
"X-API-Key": API_KEY,
"Content-Type": "application/json"
},
json={
"input": {
"feature1": ["value1"],
"feature2": [123]
}
},
params={"sync": "true"}
)
result = response.json()
print(f"Prediction: {result['data']['predictions']}")
Next Steps
- Authentication - Learn how to manage API keys
- First Prediction - Detailed walkthrough of the prediction API
- API Reference - Full endpoint documentation