🧠

Life OS API

v1

Embed AI-powered life assistance — chat, scam detection, planning — directly in your apps.

● LiveBase URL: https://api.lifeos.app

Authentication

All API requests require a bearer token. Generate keys in Settings → API Keys. API access requires a Pro or Family plan.

Authorization: Bearer lok_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Endpoints

POST/api/v1/chat

Send a message and receive an AI response. Supports multilingual replies.

Request body

{
  "message": "What should I check before buying a used car?",
  "language": "hi-IN",   // optional: BCP-47 code for response language
  "context":  "..."      // optional: system context for your app (max 1000 chars)
}

Response

{
  "text":      "यहाँ कुछ महत्वपूर्ण बातें हैं...",
  "model":     "anthropic",
  "requestId": "uuid"
}
POST/api/v1/protect

Analyse text for scams, suspicious quotes, or risky contracts.

Request body

{
  "text": "You have won ₹50 lakh! Click this link to claim now...",
  "type": "scam" // "scam" | "quote" | "contract" | "auto"
}

Response

{
  "riskLevel":      "high",
  "summary":        "This is a classic lottery scam.",
  "redFlags":       ["Unsolicited prize claim", "Urgency pressure"],
  "recommendation": "Do not click any links. Block the sender."
}
GET/api/v1/usage

Get your current month's API usage and quota.

Response

{
  "month":      "2026-04",
  "plan":       "pro",
  "aiRequests": { "used": 42, "limit": -1, "exceeded": false },
  "whatsappMessages": { "used": 5, "limit": -1, "exceeded": false }
}

Error codes

StatusMeaning
401Missing or invalid API key
403Plan does not include API access (upgrade to Pro)
400Invalid request body
429Monthly quota exceeded
500Internal server error — retry after a few seconds

Rate limits

PlanAI requests / monthAPI keys
Free50
ProUnlimited5
FamilyUnlimited5

Quick start

curl -X POST https://api.lifeos.app/api/v1/chat \
  -H "Authorization: Bearer lok_live_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"message": "Is this WhatsApp message a scam?"}'