gitlab api获取用户星标项目

获取所有项目

复制代码
gitlab_url: gitlab的地址
token: 管理员账号的access_token
https://gitlab_url/api/v4/projects/?private_token=token&page=1&per_page=20

注:该链接只获取一页的数据,可通过循环累加page遍历所有项目

获取某个用户的星标项目

参考连接:https://docs.gitlab.cn/jh/api/projects.html#列出用户加星标的项目

复制代码
gitlab_url: gitlab的地址
ueser_id: 用户的id
token: 该用户的access_token
https://gitlab_url/api/v4/users/user_id/starred_projects?private_token=token&page=1&per_page=20
注:该链接只获取一页的数据,可通过循环累加page遍历所有项目

获取项目的所有分支

复制代码
gitlab_url: gitlab的地址
token: 用户的access_token
https://gitlab_url/api/v4/projects/project_id/repository/branches?private_token=token&page=1&per_page=20

注:该链接只获取一页的数据,可通过循环累加page遍历所有项目
相关推荐
极小狐10 小时前
GitLab 安全漏洞 CVE-2025-7739 解决方案
ci/cd·gitlab·devsecops·devops·极狐gitlab
运维开发王义杰4 天前
YAML:锚点深度解析,告别重复,拥抱优雅的配置艺术
ci/cd·gitlab
hkNaruto5 天前
【Docker】openEuler 使用docker-compose部署gitlab-ce
docker·容器·gitlab
hl04068 天前
GitLab CI + Docker 自动构建前端项目并部署 — 完整流程文档
ci/cd·docker·gitlab
先天打工圣体的男人8 天前
Linux环境gitlab多种部署方式及具体使用
运维·git·gitlab
委婉待续8 天前
基于linux环境在centos7上部署gitlab
gitlab
疯狂吧小飞牛12 天前
基于ubuntu搭建gitlab
linux·ubuntu·gitlab
__Smile°14 天前
Gitlab+Jenkins+K8S+Registry 建立 CI/CD 流水线
linux·ci/cd·docker·kubernetes·gitlab·jenkins
某某14 天前
gitlab启动失败,如何解决
gitlab