Documentation API
Intégrez DPP-Tool dans vos systèmes existants.
L'accès API nécessite un plan Pro ou supérieur.
Voir les plansAuthentification
Incluez votre clé API dans l'en-tête Authorization :
Authorization: Bearer YOUR_API_KEY
Points de terminaison
GET /api/products
Listez tous vos produits avec pagination.
Réponse
{
"products": [
{
"id": "abc123",
"name": "EcoCharge Pro 5000",
"sector": "batteries",
"gtin": "4006381333931",
"created_at": "2026-01-15T10:30:00Z"
}
],
"total": 1,
"page": 1
}
POST /api/products
Créez un nouveau produit et générez automatiquement son passeport.
Corps de la requête
{
"name": "EcoCharge Pro 5000",
"sector": "batteries",
"manufacturer_name": "GreenTech GmbH",
"gtin": "4006381333931",
"carbon_footprint": 12.5,
"recycled_content": 65,
"energy_class": "A+"
}
GET /api/passport?slug={slug}&format=json
Obtenez les données du passeport au format JSON (public, aucune authentification requise).
GET /api/qrcode?slug={slug}&size=300
Générez un QR code pour un passeport (public, aucune authentification requise).
Retourne une image PNG.
GET /api/export?slug={slug}&format={json|csv}
Exportez les données du passeport dans différents formats.
Limites de débit
| Plan | Requêtes / Heure |
|---|---|
| Free | 10 |
| Pro / Business | 100 |
Codes d'erreur
| Code | Signification |
|---|---|
| 400 | Bad Request |
| 401 | Unauthorized — invalid or missing API key |
| 403 | Forbidden — plan does not include API access |
| 404 | Not Found |
| 429 | Rate Limit Exceeded |
| 500 | Internal Server Error |