List All Repositories For Authorized Users
GET/api/v5/user/repos
Request
Query Parameters
User authorization code
public, private, or all; default: all
owner (repository owner), collaborator (authorized user as a member of the repository), organization_member (authorized user as a member of the organization that owns the repository and has access to the repository), enterprise_member (authorized user as a member of the enterprise that owns the repository and has access to the repository), admin (all authorized users including all repositories in managed organizations and all repositories in managed enterprises). These can be combined with commas. For example: owner, organization_member or owner, collaborator, organization_member.
Filter user repositories: created(owner), personal, member, public, private. Cannot be used with the affiliation parameter, otherwise a 422 error will occur. Should be used with the visibility parameter, which has higher priority.
Sort by: created, updated, pushed, full_name. Default: full_name
If the sort parameter is full_name, use ascending (asc). Otherwise, use descending (desc).
Search keyword
The current page number
The number of items per page, with a maximum of 100. The default is 20.
Filter repository type, which can be code: code repository, model: model repository, dataset: dataset repository, space: space, all: all repository types. Default: code
Responses
- 200
Successful Response
Response Headers
- application/json
- Schema
- Example (auto)
- Example
Schema
- Array [
- Array [
- ]
- Array [
- ]
- ]
namespace object
assignee object[]
project_labels object[]
permission object
enterprise object
owner object
assigner object
[
{
"id": 0,
"full_name": "string",
"human_name": "string",
"url": "string",
"namespace": {
"id": 0,
"type": "string",
"name": "string",
"path": "string",
"html_url": "string"
},
"path": "string",
"name": "string",
"description": "string",
"status": "string",
"ssh_url_to_repo": "string",
"http_url_to_repo": "string",
"web_url": "string",
"homepage": "string",
"members": [
"string"
],
"assignee": [
{
"id": "string",
"login": "string",
"name": "string",
"avatar_url": "string",
"html_url": "string",
"type": "string"
}
],
"forks_count": 0,
"stargazers_count": 0,
"project_labels": [
{}
],
"relation": "string",
"permission": {
"pull": 0,
"push": 0,
"admin": 0
},
"internal": 0,
"open_issues_count": 0,
"has_issue": 0,
"watched": 0,
"watchers_count": 0,
"assignees_number": 0,
"enterprise": {
"id": 0,
"path": "string",
"html_url": "string",
"type": "string"
},
"default_branch": "string",
"fork": 0,
"owner": {
"id": "string",
"login": "string",
"name": "string",
"type": "string"
},
"assigner": {
"id": "string",
"login": "string",
"name": "string",
"type": "string"
},
"private": 0,
"public": 0,
"repo_type": "string"
}
]
{
"id": 4028329,
"full_name": "tiandi/test_yf_repo",
"human_name": "Hongmen / test_yf_repo",
"url": "https://api.gitcode.com/api/v5/repos/tiandi/test_yf_repo",
"namespace": {
"id": 1420034,
"type": "enterprise",
"name": "Red Gang",
"path": "tiandi",
"html_url": "https://gitcode.com/tiandi"
},
"path": "test_yf_repo",
"name": "test_yf_repo",
"description": "",
"status": "start",
"ssh_url_to_repo": "git@gitcode.com:tiandi/test_yf_repo.git",
"http_url_to_repo": "https://gitcode.com/tiandi/test_yf_repo.git",
"web_url": "https://gitcode.com/tiandi/test_yf_repo",
"homepage": "https://gitcode.com/tiandi/test_yf_repo",
"members": [
"aron1"
],
"assignee": [
{
"id": "332008",
"login": "aron1",
"name": "yanfan",
"avatar_url": "https://cdn-img.gitcode.com/bd/ca/0115343247b338d0c53589a145501e84a58464272f2fb09b372cc3d2311b2b39.png?time=1722525295285",
"html_url": "https://gitcode.com/aron1",
"type": "User"
}
],
"forks_count": 0,
"stargazers_count": 0,
"project_labels": [],
"relation": "master",
"permission": {
"pull": true,
"push": true,
"admin": true
},
"internal": false,
"open_issues_count": 0,
"has_issue": false,
"watched": false,
"watchers_count": 0,
"assignees_number": 1,
"enterprise": {
"id": 1420034,
"path": "tiandi",
"html_url": "https://gitcode.com/tiandi",
"type": "enterprise"
},
"default_branch": "main",
"fork": false,
"owner": {
"id": "444601",
"login": "yanfan",
"name": "abcabcabc",
"type": "User"
},
"assigner": {
"id": "444601",
"login": "yanfan",
"name": "abcabcabc",
"type": "User"
},
"private": true,
"public": false
}