API Clients OAuth
Gérez les clients OAuth 2.0 / OIDC (applications) au sein de vos espaces de travail.
Créer un Client
Crée une nouvelle application client OAuth 2.0.
Requête
curl -X POST https://api.syauth.com/e/v1/developer/clients/ \
-H "X-Developer-Token: syat_..." \
-H "Content-Type: application/json" \
-d '{
"name": "My New App",
"client_type": "public",
"response_types": ["code"],
"redirect_uris": ["https://localhost:3000/callback"],
"allowed_grant_types": ["authorization_code"],
"allowed_response_types": ["code"],
"allowed_scopes": ["openid", "profile"],
"workspace": "78047707-5f8f-472b-a065-3d3dc48ba80a"
}'
Réponse
{
"id": "10e3a0f2-488b-47aa-84b0-5c933db93a75",
"name": "My New App",
"client_id": "dc4d9176-37...",
"client_type": "public",
"workspace_id": "78047707-5f8f-472b-a065-3d3dc48ba80a",
"redirect_uris": ["https://localhost:3000/callback"],
"is_active": true,
"created_at": "2026-01-07T10:05:00Z"
}
Lister les Clients
Liste tous les clients OAuth.
Requête
curl -X GET https://api.syauth.com/e/v1/developer/clients/ \
-H "X-Developer-Token: syat_..."
Réponse
[
{
"id": "10e3a0f2-488b-47aa-84b0-5c933db93a75",
"name": "Main Application",
"client_id": "dc4d9176-37...",
"client_type": "confidential",
"workspace_id": "78047707-5f8f-472b-a065-3d3dc48ba80a",
"redirect_uris": ["https://app.example.com/callback"],
"is_active": true
}
]
Obtenir les Détails d'un Client
Requête
curl -X GET https://api.syauth.com/e/v1/developer/clients/10e3a0f2-488b-47aa-84b0-5c933db93a75/ \
-H "X-Developer-Token: syat_..."
Réponse
{
"id": "10e3a0f2-488b-47aa-84b0-5c933db93a75",
"name": "My New App",
"client_id": "dc4d9176-37...",
"client_type": "public",
"workspace_id": "78047707-5f8f-472b-a065-3d3dc48ba80a",
"redirect_uris": ["https://localhost:3000/callback"],
"is_active": true,
"created_at": "2026-01-07T10:05:00Z"
}
Mettre à Jour un Client
Modifie un client OAuth existant.
Requête
curl -X PUT https://api.syauth.com/e/v1/developer/clients/10e3a0f2-488b-47aa-84b0-5c933db93a75/ \
-H "X-Developer-Token: syat_..." \
-H "Content-Type: application/json" \
-d '{"name": "My New App Updated", "redirect_uris": ["https://app.example.com/callback"]}'
Réponse
{
"id": "10e3a0f2-488b-47aa-84b0-5c933db93a75",
"name": "My New App Updated",
"client_id": "dc4d9176-37...",
"client_type": "public",
"workspace_id": "78047707-5f8f-472b-a065-3d3dc48ba80a",
"redirect_uris": ["https://app.example.com/callback"],
"is_active": true,
"created_at": "2026-01-07T10:05:00Z"
}
Supprimer un Client
Supprime définitivement un client OAuth.
Requête
curl -X DELETE https://api.syauth.com/e/v1/developer/clients/10e3a0f2-488b-47aa-84b0-5c933db93a75/ \
-H "X-Developer-Token: syat_..."
Réponse
204 No Content