Description
The GitLab REST API returns a shared_with_groups array on both the
project (GET /projects/:id) and group (GET /groups/:id) responses,
but this property is not mapped in NGitLab.Models.Project or
NGitLab.Models.Group. As a result, consumers can't see which groups a
project/group has been shared with.
API reference
Example payload
"shared_with_groups": [
{
"group_id": 4,
"group_name": "Twitter",
"group_full_path": "twitter",
"group_access_level": 30,
"expires_at": null
}
]
Proposed change
- Add a new model type (e.g.
SharedWithGroup) mapping group_id,
group_name, group_full_path, group_access_level and expires_at.
- Add
[JsonPropertyName("shared_with_groups")] public SharedWithGroup[] SharedWithGroups { get; set; }
to both Project and Group.
- Mirror this in
NGitLab.Mock and add tests.
Description
The GitLab REST API returns a
shared_with_groupsarray on both theproject (
GET /projects/:id) and group (GET /groups/:id) responses,but this property is not mapped in
NGitLab.Models.ProjectorNGitLab.Models.Group. As a result, consumers can't see which groups aproject/group has been shared with.
API reference
Example payload
Proposed change
SharedWithGroup) mappinggroup_id,group_name,group_full_path,group_access_levelandexpires_at.[JsonPropertyName("shared_with_groups")] public SharedWithGroup[] SharedWithGroups { get; set; }to both
ProjectandGroup.NGitLab.Mockand add tests.