get_file_contents
Fetch contents of a file or directory from a GitLab project. Specify branch, tag, or commit and optionally filter results with JMESPath.
Instructions
Get contents of a file or directory from a GitLab project. Read-only; missing resources, denied access, and rate limits return errors. project_id/group_id take a numeric ID or URL-encoded path.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | Branch/tag/commit to get contents from | |
| path | No | Alias of file_path | |
| jmespath | No | Optional JMESPath expression filtering the JSON result before return. | |
| file_path | No | Path to the file or directory. Takes precedence over 'path' when both are provided | |
| project_id | No | Project ID or URL-encoded path (optional; falls back to env) |