PMaaS API
Integrate Vehk data into your own systems.
Authentication
All API requests require an API key:
Authorization: Bearer YOUR_API_KEY
Get Your API Key
- Dashboard → Settings → API Keys
- Click "Create New Key"
- Name it (e.g., "Production")
- Copy immediately (shown only once)
Example: sk_live_1234567890abcdef
Base URL
Production API endpoints:
| Environment | Base URL |
|---|---|
| Production | https://vehk-api.bravedune-34ccdec3.centralindia.azurecontainerapps.io/api/v1 |
| Dashboard | https://axle.vehk.in |
API Documentation
Full interactive API documentation (Swagger) is available at your API base URL + /docs
Common Endpoints
List Vehicles
GET /vehicles
Response:
{
"vehicles": [
{
"id": "MH01AB1234",
"vin": "1HGBH41JXMN109186",
"make": "Tata",
"model": "LPT 1518",
"healthScore": 87.5
}
]
}
Get Vehicle Health
GET /vehicles/{id}/health
Response:
{
"vehicleId": "MH01AB1234",
"healthScore": 87.5,
"components": {
"engine": 92,
"transmission": 85,
"brakes": 78
},
"alerts": []
}
Get Predictions
GET /predictions?vehicleId={id}
Response:
{
"predictions": [
{
"vehicleId": "MH01AB1234",
"component": "battery",
"issue": "Voltage degradation detected",
"rul_days": 45,
"confidence": 0.87,
"severity": "medium"
}
]
}
Get Alerts
GET /alerts?severity=critical
Response:
{
"alerts": [
{
"id": "alert_123",
"vehicleId": "MH01AB1234",
"severity": "critical",
"message": "Engine overheating detected",
"timestamp": "2026-01-12T10:00:00Z"
}
]
}
Ingest Telemetry Data
Push vehicle telemetry data to Vehk:
Via REST API
POST /telemetry
Content-Type: application/json
Authorization: Bearer YOUR_API_KEY
Request Body:
{
"vehicleId": "MH01AB1234",
"timestamp": "2026-01-13T10:00:00Z",
"engine_speed": 2400,
"coolant": 92,
"battery_voltage": 13.2,
"vehicleSpeed": 65
}
Via Kafka
For high-volume streaming, use Kafka integration:
- Go to Settings → Kafka Config in the dashboard
- Configure your Kafka broker connection
- Publish telemetry messages to the configured topic
Rate Limits
| Plan | Rate Limit |
|---|---|
| Starter | 100,000 calls/month |
| Professional | Unlimited |
| Enterprise | Unlimited |
Webhooks
Receive real-time notifications:
Setup
- Dashboard → Settings → Webhooks
- Add endpoint URL
- Select events to receive
Events
| Event | Description |
|---|---|
vehicle.health.changed | Health score changed significantly |
alert.created | New alert generated |
prediction.created | New maintenance prediction |
maintenance.completed | Maintenance marked complete |
Example Payload:
{
"event": "alert.created",
"timestamp": "2026-01-13T10:00:00Z",
"data": {
"vehicleId": "MH01AB1234",
"severity": "critical",
"message": "Brake failure predicted in 7 days"
}
}
Code Examples
Python
import requests
API_KEY = "sk_live_your_api_key"
BASE_URL = "https://vehk-api.bravedune-34ccdec3.centralindia.azurecontainerapps.io/api/v1"
headers = {
"Authorization": f"Bearer {API_KEY}",
"Content-Type": "application/json"
}
# Get all vehicles
response = requests.get(f"{BASE_URL}/vehicles", headers=headers)
vehicles = response.json()
# Get predictions for a vehicle
response = requests.get(f"{BASE_URL}/predictions?vehicleId=MH01AB1234", headers=headers)
predictions = response.json()
JavaScript
const API_KEY = 'sk_live_your_api_key';
const BASE_URL = 'https://vehk-api.bravedune-34ccdec3.centralindia.azurecontainerapps.io/api/v1';
// Get all vehicles
const response = await fetch(`${BASE_URL}/vehicles`, {
headers: {
'Authorization': `Bearer ${API_KEY}`,
'Content-Type': 'application/json'
}
});
const vehicles = await response.json();
cURL
curl -X GET "https://vehk-api.bravedune-34ccdec3.centralindia.azurecontainerapps.io/api/v1/vehicles" \
-H "Authorization: Bearer sk_live_your_api_key" \
-H "Content-Type: application/json"
Error Handling
All errors return JSON:
{
"error": {
"code": "invalid_api_key",
"message": "The API key provided is invalid"
}
}
Common Errors:
| Status | Code | Description |
|---|---|---|
400 | invalid_request | Malformed request |
401 | invalid_api_key | API key is invalid or missing |
404 | not_found | Resource not found |
429 | rate_limit_exceeded | Too many requests |
500 | server_error | Internal server error |
Next Steps
- Dashboard Guide - Learn the dashboard features
- Getting Started - Initial setup
- Pricing - Compare plans