I’ve created a way to migrate Github Gists to Snippets in Gitlab. The last sticking point is the notes.
This doc: https://docs.gitlab.com/ee/api/notes.html shows how to add notes to Snippets which are on projects. However, the way I created snippets was with the
/api/v4/snippets endpoint. Adding the snippet id and notes
/api/v4/snippets/123/notes returns a 404 not found. In the UI the snippet link has
/-/snippet/123 as the url. When I add a note in the UI it POSTs to the same URL with form field data. I tried this as well, but it won’t auth, I think because of the activation token.
Is there some way to post to
/api/v4/projects/:id/snippets/123/notes where the project id is absent? I tried
- and that was 404 as well. Or is there an undocumented way to do create snippet notes?