Référence API
Tous les endpoints de julakAI OTP.
Base URL
https://api.otp.julakai.comhttp://localhost:3100 (dev local)Authentification
Endpoints /v1/otp/* : signature HMAC-SHA256. Endpoints /v1/dashboard/* : session cookie.
Message signé :
method + url + timestamp + rawBodyurl inclut la query string pour les GET.POST
/v1/otp/sendEnvoyer un OTP
Body
{ "phone": "+22375673336" }Réponse
{ "requestId": "otp_...", "expiresInSeconds": 300 }400 format · 402 quota · 429 cooldown · 503 échec
POST
/v1/otp/verifyVérifier un OTP
Body
{ "phone": "+22375673336", "code": "1234" }Réponse
{ "verified": true, "verificationToken": "eyJhbG..." }401 expiré/invalide · 403 verrouillé
GET
/v1/otp/status?phone=+22375673336État d'un OTP
Réponse
{ "state": "pending", "expiresInSeconds": 187 }POST
/v1/appsCréer une app
Header X-Admin-Key requis. appSecret affiché une seule fois.
Body
{ "name": "Mon App", "senderName": "MonApp", "ownerEmail": "moi@exemple.com" }Réponse
{ "appId": "...", "appKey": "jak_live_...", "appSecret": "sk_live_..." }PATCH
/v1/apps/:id/planChanger le plan
Header X-Admin-Key requis.
Body
{ "planStatus": "active", "dailyQuota": 500 }Réponse
{ "appId": "...", "planStatus": "active", "dailyQuota": 500 }