python-gitlab v3.14.0中后代组数据结构实例
时间: 2024-02-29 09:54:23 浏览: 124
以下是python-gitlab v3.14.0中后代组(Group Descendant)的数据结构示例:
```python
{
"id": 1,
"name": "Group 1",
"full_path": "group1",
"description": "This is Group 1",
"parent_id": None,
"visibility": "private",
"lfs_enabled": True,
"avatar_url": None,
"web_url": "https://gitlab.example.com/groups/group1",
"request_access_enabled": False,
"share_with_group_lock": False,
"require_two_factor_authentication": False,
"two_factor_grace_period": None,
"project_creation_level": "developer",
"auto_devops_enabled": False,
"subgroup_creation_level": "maintainer",
"emails_disabled": False,
"mentions_disabled": False,
"default_branch_protection": 2,
"created_at": "2022-01-01T00:00:00.000Z",
"updated_at": "2022-01-01T00:00:00.000Z",
"children": [
{
"id": 2,
"name": "Subgroup 1",
"full_path": "group1/subgroup1",
"description": "This is Subgroup 1",
"parent_id": 1,
"visibility": "private",
"lfs_enabled": True,
"avatar_url": None,
"web_url": "https://gitlab.example.com/groups/group1/subgroup1",
"request_access_enabled": False,
"share_with_group_lock": False,
"require_two_factor_authentication": False,
"two_factor_grace_period": None,
"project_creation_level": "developer",
"auto_devops_enabled": False,
"subgroup_creation_level": "maintainer",
"emails_disabled": False,
"mentions_disabled": False,
"default_branch_protection": 2,
"created_at": "2022-01-01T00:00:00.000Z",
"updated_at": "2022-01-01T00:00:00.000Z",
"children": []
},
{
"id": 3,
"name": "Subgroup 2",
"full_path": "group1/subgroup2",
"description": "This is Subgroup 2",
"parent_id": 1,
"visibility": "private",
"lfs_enabled": True,
"avatar_url": None,
"web_url": "https://gitlab.example.com/groups/group1/subgroup2",
"request_access_enabled": False,
"share_with_group_lock": False,
"require_two_factor_authentication": False,
"two_factor_grace_period": None,
"project_creation_level": "developer",
"auto_devops_enabled": False,
"subgroup_creation_level": "maintainer",
"emails_disabled": False,
"mentions_disabled": False,
"default_branch_protection": 2,
"created_at": "2022-01-01T00:00:00.000Z",
"updated_at": "2022-01-01T00:00:00.000Z",
"children": []
}
]
}
```
该数据结构包含了一个组(Group)的基本信息,包括组的ID、名称、描述、可见性、是否启用 LFS、头像链接、网页链接、创建时间、更新时间等等。此外,还包含了该组的所有后代子组(Subgroup)的信息,以嵌套的方式展示。每个子组也包含了相同的基本信息和子组信息。
阅读全文