Add raw snippet file endpoint
What does this MR do?
Adds a new API endpoint for returning the raw content of a given file at a given ref.
This will allow users to query for a specific file/ref combination, inline with the functionality added via the new raw snippet action in #217775 (closed)
Refs #218226 (closed)
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers -
Informed Infrastructure department of a default or new setting change, if applicable per definition of done
This MR can be manually tested using variations of the following:
curl --header "PRIVATE-TOKEN: <your_access_token>" "http://127.0.0.1:3000/api/v4/snippets/<snippet_id>/raw/<ref>/<snippet_file_name>"
Edited by Vijay Hawoldar