Aller au contenu
GET /v1/spf

SPF needed for a duration

Essayez-le en direct

10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.

En-têtes personnalisés (facultatif)
api.oanor.com/sunscreen-api

Ça marche. Récupérez une clé API et utilisez-la dans votre projet.

Obtenez une clé API

Extraits de code

curl "https://api.oanor.com/sunscreen-api/v1/spf" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/sunscreen-api/v1/spf", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/sunscreen-api/v1/spf");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/sunscreen-api/v1/spf",
    headers={"x-oanor-key": "oanor_test_..."}
)

Exemple de réponse

Une réponse réelle de ce endpoint, capturée lors du dernier contrôle de santé.

{
    "data": {
        "note": "SPF needed = desired minutes ÷ unprotected burn time. Real-world advice caps out around SPF 30–50 — above that the extra protection is marginal (SPF 30 blocks ~97 %, SPF 50 ~98 %) and people apply too little. Reapply rather than chase a huge number.",
        "inputs": {
            "uv_index": 8,
            "skin_type": 3,
            "desired_minutes": 240
        },
        "spf_needed": 16,
        "unprotected_minutes": 15
    },
    "meta": {
        "timestamp": "2026-06-06T15:30:48.828Z",
        "request_id": "43aa03b8-cee8-44e9-aa4c-66fdffa28ead"
    },
    "status": "ok",
    "message": "SPF needed",
    "success": true
}