Created
February 6, 2026 16:19
-
-
Save fedir/d62e0b80458bd340ac01b06bb4258215 to your computer and use it in GitHub Desktop.
Gitlab API avec curl
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Cas d'usage / Action | Requête CURL | |
|---|---|---|
| Lister tous les projets (visibles par vous) | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/projects" | |
| Lister les projets d'un groupe | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/groups/<ID>/projects" | |
| Lister incluant les sous-groupes | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/groups/<ID>/projects?include_subgroups=true" | |
| Chercher un texte dans un projet (Code) | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/projects/<ID>/search?scope=blobs&search=<votre_texte>" | |
| Trouver l'ID d'un groupe par son nom | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/groups?search=<nom_du_groupe>" | |
| Vérifier validité Token / Utilisateur | curl --header "PRIVATE-TOKEN: <token>" "https://gitlab.company/api/v4/user" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment