API Documentation

API OptimonCV

Intégrez l'analyse ATS directement dans votre application avec notre API REST authentifiée par votre token Supabase.

Temps de réponse < 3s
Auth JWT Supabase
RESTful JSON

Authentification

Toutes les requêtes nécessitent votre JWT Supabase (access_token) dans le header Authorization. Récupérez-le après connexion via supabase.auth.getSession().

Authorization: Bearer <votre_access_token>

POST /api/v1/cv/analyze

Analyse un CV par rapport à une offre d'emploi et retourne un score ATS détaillé. Consomme 1 crédit par appel (illimité sur le plan Pro).

Corps de la requête

{
  "cv_content":      "string  — texte brut du CV (obligatoire)",
  "job_description": "string  — texte de l'offre d'emploi (obligatoire)",
  "job_title":       "string  — intitulé du poste (optionnel)"
}

Réponse 200

{
  "ats_score":   85,
  "keywords":    { "missing": ["React", "TypeScript"] },
  "strengths":   ["Expérience en Node.js", "Projets open-source"],
  "weaknesses":  ["Pas de mention de tests unitaires"],
  "suggestions": ["Ajoutez vos certifications AWS"],
  "credits_remaining": 12
}

Exemple complet

// 1. Récupérer le token après connexion
const { data: { session } } = await supabase.auth.getSession();
const token = session?.access_token;

// 2. Appeler l'API
const response = await fetch("https://optimoncv.com/api/v1/cv/analyze", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${token}`,
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    cv_content: "Jean Dupont\nDéveloppeur React 5 ans...",
    job_description: "Senior React Developer — TypeScript, Node.js...",
    job_title: "Senior React Developer"
  })
});

const result = await response.json();
console.log("Score ATS :", result.ats_score + "%");
console.log("Mots-clés manquants :", result.keywords.missing.join(", "));

Codes d'erreur

CodeSignification
401Token manquant ou expiré
400cv_content ou job_description manquant
402Crédits insuffisants — passez au plan Pro
409Conflit de crédits — réessayez
429Trop de requêtes — max 5 / 5 minutes
503Service IA temporairement indisponible

Accès API inclus dans votre plan

Pas de plan API séparé — l'accès à l'API utilise vos crédits d'analyse existants.

Free

0/mois
  • 3 crédits/mois
  • Auth JWT incluse
  • 5 req / 5 min
Choisir Free

Starter

9/mois
  • 30 crédits/mois
  • Auth JWT incluse
  • 5 req / 5 min
Choisir Starter
Populaire

Pro

19/mois
  • Illimité
  • Auth JWT incluse
  • 5 req / 5 min
Choisir Pro

Prêt à intégrer l'analyse ATS ?

Créez un compte gratuit et obtenez votre token en 30 secondes.

Commencer gratuitement