Milestone API not working correctly on private projects
<!--IssueSummary start--> <details> <summary> Everyone can contribute. [Help move this issue forward](https://handbook.gitlab.com/handbook/marketing/developer-relations/contributor-success/community-contributors-workflows/#contributor-links) while earning points, leveling up and collecting rewards. </summary> - [Close this issue](https://contributors.gitlab.com/manage-issue?action=close&projectId=278964&issueIid=27445) </details> <!--IssueSummary end--> ### Summary The following endpoints according to the docs do not return anything on private projects: * https://docs.gitlab.com/ee/api/group_milestones.html#get-all-issues-assigned-to-a-single-milestone * https://docs.gitlab.com/ee/api/group_milestones.html#get-all-merge-requests-assigned-to-a-single-milestone ### Steps to reproduce Install `jq` as dependency to be able to get information from JSON ```bash GITLAB_API_TOKEN="YOURTOKEN" GROUP_ID="gitlab-org" ACTIVE_MILESTONE_ID="$(curl --fail --silent --show-error --request GET --header "PRIVATE-TOKEN: ${GITLAB_API_TOKEN}" "https://gitlab.com/api/v4/groups/${GROUP_ID}/milestones?state=active" | jq '.[0].id')" curl --header "PRIVATE-TOKEN: ${GITLAB_API_TOKEN}" https://gitlab.com/api/v4/groups/${GROUP_ID}/milestones/${ACTIVE_MILESTONE_ID}/issues ``` Above works, but when your change `GROUP_ID` to a private project ID or private project urlencoded namespace it will always return an empty array even when the milestone has some issues and merge requests added to it. ### Example Project N/A ### What is the current *bug* behavior? API return empty array instead of the issues or merge requests attached to it ### What is the expected *correct* behavior? It should return the issues and merge requests ### Relevant logs and/or screenshots N/A ### Output of checks This bug happens on GitLab.com ### Possible fixes N/A
issue