# Model registry

Download the files of a model version from a project's GitLab model registry.

Source: https://docs.jmrp.io/gitlab-mcp-server/reference/tools/model-registry/
Updated: 2026-11-22

---

The model registry keeps machine learning models and their versions in a project. `model_registry.download` fetches one file of a model version, for inference, evaluation or a build. Publishing and deleting model versions are not actions of this server.

## Sample questions

- "Download model.onnx from version 3 of the classifier model in project 42"

## How to call it

- **Dynamic**, the default surface: call `gitlab_execute_action` with `action` set to the action's ID, such as `model_registry.download`, and its parameters in `params`. `gitlab_find_action` finds an ID from a description of the task.
- **Meta** (`GITLAB_MCP_TOOL_SURFACE=meta`): call `gitlab_model_registry` with `action` set to the action's name, such as `download`, and its parameters in `params`.
- **Individual** (`GITLAB_MCP_TOOL_SURFACE=individual`): call the action's own tool, such as `gitlab_download_ml_model_package`, with its parameters as the arguments.

## Availability

Every tier serves the whole group, on self-managed instances and on GitLab.com alike.

Read-only actions: 1 of 1, the ones a deployment in read-only mode keeps. A token with `read_api` and not `api` is served 1 of the 1.

## Actions

The description of each action, and of each of its parameters, is the text the server serves for it on the default surface, quoted as served. The token lines say what GitLab 19.6.1 requires of a token for the requests each action sends; on an instance with Admin Mode turned on, an action only an administrator may run also needs `admin_mode`.

| Action | Individual |
| --- | --- |
| [`model_registry.download`](https://docs.jmrp.io/gitlab-mcp-server/reference/tools/model-registry/#model_registrydownload) | `gitlab_download_ml_model_package` |

### `model_registry.download`

> Download one artifact file from a project ML model registry package version by project, model version, path (empty for a file at the package root), and filename. Returns: the artifact bytes base64-encoded in content_base64, plus project, model version, path, filename, and decoded size_bytes. See also: [`package.list`](https://docs.jmrp.io/gitlab-mcp-server/reference/tools/package/#packagelist), [`release.link_create`](https://docs.jmrp.io/gitlab-mcp-server/reference/tools/release/#releaselink_create), [`repository.raw_blob`](https://docs.jmrp.io/gitlab-mcp-server/reference/tools/repository/#repositoryraw_blob).

- **Meta-tool**: `gitlab_model_registry`, action `download`
- **Individual tool**: `gitlab_download_ml_model_package`
- **Tier**: Free
- **Classic or OAuth token**: `read_api` (or `api`); not an OAuth token, which GitLab refuses on `GET /projects/:id/packages/ml_models/:model_version_id/files/(*path/):file_name`
- **Fine-grained token**: Model Version: Read at project ([permissions page](https://docs.jmrp.io/gitlab-mcp-server/reference/fine-grained-permissions/#model_registry))
- **Behavior**: read-only, idempotent

| Parameter | Type | Mandatory | Description |
| --- | --- | --- | --- |
| `filename` | `string` | yes | Name of the file to download |
| `model_version_id` | `string/integer` | yes | Model version ID. Either the numeric version ID from the model version URL or a candidate run ID prefixed with candidate: such as candidate:5 |
| `project_id` | `string/integer` | yes | Project ID or URL-encoded path |
| `path` | `string` | no | Directory of the file within the model package (such as models or sub/dir). Leave it empty or pass . for a file at the package root |
