naftiko: 1.0.0-alpha2 info: label: GitLab API — job_artifacts description: 'GitLab API — job_artifacts. 8 operations. Lead operation: Download the artifacts archive from a job. Self-contained Naftiko capability covering one Gitlab Ci business surface.' tags: - Gitlab Ci - job_artifacts created: '2026-05-19' modified: '2026-05-19' binds: - namespace: env keys: GITLAB_CI_API_KEY: GITLAB_CI_API_KEY capability: consumes: - type: http namespace: gitlab-ci-job-artifacts baseUri: https://gitlab.com description: GitLab API — job_artifacts business capability. Self-contained, no shared references. resources: - name: api-v4-projects-id-artifacts path: /api/v4/projects/{id}/artifacts operations: - name: deleteapiv4projectsidartifacts method: DELETE description: Expire the artifacts files from a project outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: api-v4-projects-id-jobs-artifacts-ref_name-download path: /api/v4/projects/{id}/jobs/artifacts/{ref_name}/download operations: - name: getapiv4projectsidjobsartifactsrefnamedownload method: GET description: Download the artifacts archive from a job outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: ref_name in: path type: string description: Branch or tag name in repository. `HEAD` or `SHA` references are not supported. required: true - name: job in: query type: string description: The name of the job. required: true - name: job_token in: query type: string description: To be used with triggers for multi-project pipelines, available only on Premium and Ultimate tiers. - name: search_recent_successful_pipelines in: query type: boolean description: Search across recent successful pipelines instead of just the latest one. - name: api-v4-projects-id-jobs-artifacts-ref_name-raw-*artifact_path path: /api/v4/projects/{id}/jobs/artifacts/{ref_name}/raw/*artifact_path operations: - name: getapiv4projectsidjobsartifactsrefnamerawartifactpath method: GET description: Download a specific file from artifacts archive from a ref outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: ref_name in: path type: string description: Branch or tag name in repository. `HEAD` or `SHA` references are not supported. required: true - name: job in: query type: string description: The name of the job. required: true - name: artifact_path in: query type: string description: Path to a file inside the artifacts archive. required: true - name: job_token in: query type: string description: To be used with triggers for multi-project pipelines, available only on Premium and Ultimate tiers. - name: search_recent_successful_pipelines in: query type: boolean description: Search across recent successful pipelines instead of just the latest one. - name: api-v4-projects-id-jobs-job_id-artifacts path: /api/v4/projects/{id}/jobs/{job_id}/artifacts operations: - name: getapiv4projectsidjobsjobidartifacts method: GET description: Download the artifacts archive from a job outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: job_id in: path type: integer description: The ID of a job required: true - name: job_token in: query type: string description: To be used with triggers for multi-project pipelines, available only on Premium and Ultimate tiers. - name: deleteapiv4projectsidjobsjobidartifacts method: DELETE description: Delete the artifacts files from a job outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: job_id in: path type: integer description: The ID of a job required: true - name: api-v4-projects-id-jobs-job_id-artifacts-*artifact_path path: /api/v4/projects/{id}/jobs/{job_id}/artifacts/*artifact_path operations: - name: getapiv4projectsidjobsjobidartifactsartifactpath method: GET description: Download a specific file from artifacts archive outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: job_id in: path type: integer description: The ID of a job required: true - name: artifact_path in: query type: string description: Path to a file inside the artifacts archive. required: true - name: job_token in: query type: string description: To be used with triggers for multi-project pipelines, available only on Premium and Ultimate tiers. - name: api-v4-projects-id-jobs-job_id-artifacts-keep path: /api/v4/projects/{id}/jobs/{job_id}/artifacts/keep operations: - name: postapiv4projectsidjobsjobidartifactskeep method: POST description: Keep the artifacts to prevent them from being deleted outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: job_id in: path type: integer description: The ID of a job required: true - name: api-v4-projects-id-jobs-job_id-artifacts-tree path: /api/v4/projects/{id}/jobs/{job_id}/artifacts/tree operations: - name: getapiv4projectsidjobsjobidartifactstree method: GET description: List all files in the artifacts archive outputRawFormat: json outputParameters: - name: result type: object value: $. inputParameters: - name: id in: path type: string description: The ID or URL-encoded path of the project required: true - name: job_id in: path type: integer description: ID of a job required: true - name: path in: query type: string description: Path to browse in the artifacts archive. Defaults to root directory. - name: recursive in: query type: boolean description: If `true`, return all entries recursively. - name: job_token in: query type: string description: CI/CD job token for multi-project pipelines. Premium and Ultimate only. - name: page in: query type: integer description: Current page number - name: per_page in: query type: integer description: Number of items per page exposes: - type: rest namespace: gitlab-ci-job-artifacts-rest port: 8080 description: REST adapter for GitLab API — job_artifacts. One Spectral-compliant resource per consumed operation, prefixed with /v1. resources: - path: /v1/api/v4/projects/{id}/artifacts name: api-v4-projects-id-artifacts description: REST surface for api-v4-projects-id-artifacts. operations: - method: DELETE name: deleteapiv4projectsidartifacts description: Expire the artifacts files from a project call: gitlab-ci-job-artifacts.deleteapiv4projectsidartifacts with: id: rest.id outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/artifacts/{ref-name}/download name: api-v4-projects-id-jobs-artifacts-ref-name-download description: REST surface for api-v4-projects-id-jobs-artifacts-ref_name-download. operations: - method: GET name: getapiv4projectsidjobsartifactsrefnamedownload description: Download the artifacts archive from a job call: gitlab-ci-job-artifacts.getapiv4projectsidjobsartifactsrefnamedownload with: id: rest.id ref_name: rest.ref_name job: rest.job job_token: rest.job_token search_recent_successful_pipelines: rest.search_recent_successful_pipelines outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/artifacts/{ref-name}/raw/artifact-path name: api-v4-projects-id-jobs-artifacts-ref-name-raw-artifact-path description: REST surface for api-v4-projects-id-jobs-artifacts-ref_name-raw-*artifact_path. operations: - method: GET name: getapiv4projectsidjobsartifactsrefnamerawartifactpath description: Download a specific file from artifacts archive from a ref call: gitlab-ci-job-artifacts.getapiv4projectsidjobsartifactsrefnamerawartifactpath with: id: rest.id ref_name: rest.ref_name job: rest.job artifact_path: rest.artifact_path job_token: rest.job_token search_recent_successful_pipelines: rest.search_recent_successful_pipelines outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/{job-id}/artifacts name: api-v4-projects-id-jobs-job-id-artifacts description: REST surface for api-v4-projects-id-jobs-job_id-artifacts. operations: - method: GET name: getapiv4projectsidjobsjobidartifacts description: Download the artifacts archive from a job call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifacts with: id: rest.id job_id: rest.job_id job_token: rest.job_token outputParameters: - type: object mapping: $. - method: DELETE name: deleteapiv4projectsidjobsjobidartifacts description: Delete the artifacts files from a job call: gitlab-ci-job-artifacts.deleteapiv4projectsidjobsjobidartifacts with: id: rest.id job_id: rest.job_id outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/{job-id}/artifacts/artifact-path name: api-v4-projects-id-jobs-job-id-artifacts-artifact-path description: REST surface for api-v4-projects-id-jobs-job_id-artifacts-*artifact_path. operations: - method: GET name: getapiv4projectsidjobsjobidartifactsartifactpath description: Download a specific file from artifacts archive call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifactsartifactpath with: id: rest.id job_id: rest.job_id artifact_path: rest.artifact_path job_token: rest.job_token outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/{job-id}/artifacts/keep name: api-v4-projects-id-jobs-job-id-artifacts-keep description: REST surface for api-v4-projects-id-jobs-job_id-artifacts-keep. operations: - method: POST name: postapiv4projectsidjobsjobidartifactskeep description: Keep the artifacts to prevent them from being deleted call: gitlab-ci-job-artifacts.postapiv4projectsidjobsjobidartifactskeep with: id: rest.id job_id: rest.job_id outputParameters: - type: object mapping: $. - path: /v1/api/v4/projects/{id}/jobs/{job-id}/artifacts/tree name: api-v4-projects-id-jobs-job-id-artifacts-tree description: REST surface for api-v4-projects-id-jobs-job_id-artifacts-tree. operations: - method: GET name: getapiv4projectsidjobsjobidartifactstree description: List all files in the artifacts archive call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifactstree with: id: rest.id job_id: rest.job_id path: rest.path recursive: rest.recursive job_token: rest.job_token page: rest.page per_page: rest.per_page outputParameters: - type: object mapping: $. - type: mcp namespace: gitlab-ci-job-artifacts-mcp port: 9090 transport: http description: MCP adapter for GitLab API — job_artifacts. One tool per consumed operation, routed inline through this capability's consumes block. tools: - name: expire-artifacts-files-project description: Expire the artifacts files from a project hints: readOnly: false destructive: true idempotent: true call: gitlab-ci-job-artifacts.deleteapiv4projectsidartifacts with: id: tools.id outputParameters: - type: object mapping: $. - name: download-artifacts-archive-job description: Download the artifacts archive from a job hints: readOnly: true destructive: false idempotent: true call: gitlab-ci-job-artifacts.getapiv4projectsidjobsartifactsrefnamedownload with: id: tools.id ref_name: tools.ref_name job: tools.job job_token: tools.job_token search_recent_successful_pipelines: tools.search_recent_successful_pipelines outputParameters: - type: object mapping: $. - name: download-specific-file-artifacts-archive description: Download a specific file from artifacts archive from a ref hints: readOnly: true destructive: false idempotent: true call: gitlab-ci-job-artifacts.getapiv4projectsidjobsartifactsrefnamerawartifactpath with: id: tools.id ref_name: tools.ref_name job: tools.job artifact_path: tools.artifact_path job_token: tools.job_token search_recent_successful_pipelines: tools.search_recent_successful_pipelines outputParameters: - type: object mapping: $. - name: download-artifacts-archive-job-2 description: Download the artifacts archive from a job hints: readOnly: true destructive: false idempotent: true call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifacts with: id: tools.id job_id: tools.job_id job_token: tools.job_token outputParameters: - type: object mapping: $. - name: delete-artifacts-files-job description: Delete the artifacts files from a job hints: readOnly: false destructive: true idempotent: true call: gitlab-ci-job-artifacts.deleteapiv4projectsidjobsjobidartifacts with: id: tools.id job_id: tools.job_id outputParameters: - type: object mapping: $. - name: download-specific-file-artifacts-archive-2 description: Download a specific file from artifacts archive hints: readOnly: true destructive: false idempotent: true call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifactsartifactpath with: id: tools.id job_id: tools.job_id artifact_path: tools.artifact_path job_token: tools.job_token outputParameters: - type: object mapping: $. - name: keep-artifacts-prevent-them-being description: Keep the artifacts to prevent them from being deleted hints: readOnly: false destructive: false idempotent: false call: gitlab-ci-job-artifacts.postapiv4projectsidjobsjobidartifactskeep with: id: tools.id job_id: tools.job_id outputParameters: - type: object mapping: $. - name: list-all-files-artifacts-archive description: List all files in the artifacts archive hints: readOnly: true destructive: false idempotent: true call: gitlab-ci-job-artifacts.getapiv4projectsidjobsjobidartifactstree with: id: tools.id job_id: tools.job_id path: tools.path recursive: tools.recursive job_token: tools.job_token page: tools.page per_page: tools.per_page outputParameters: - type: object mapping: $.