1
Exemples CURL
francois.baille edited this page 2025-05-04 05:53:01 +02:00

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"}'