Ajouter Exemples CURL

francois.baille 2025-05-04 05:53:01 +02:00
parent de2868b0b3
commit e85bf4b057

13
Exemples-CURL.md Normal file

@ -0,0 +1,13 @@
# Authentification
curl -X POST https://148.113.194.48:8000/auth/login \
-H "Content-Type: application/json" \
-d '{"email":"user@test.com","password":"secret"}'
# Récupérer les événements
curl -X GET https://148.113.194.48:8000/events \
-H "Authorization: Bearer VOTRE_JWT"
# Créer un utilisateur (admin)
curl -X POST https://148.113.194.48:8000/users \
-H "Authorization: Bearer ADMIN_JWT" \
-d '{"username":"new","email":"new@test.com","password":"pass","role":"user"}'