---
title: "Validate a CI/CD configuration"
method: POST
path: "/api/v4/projects/{id}/ci/lint"
tags: ["ci_lint"]
---

# Validate a CI/CD configuration

`POST /api/v4/projects/{id}/ci/lint`

## Request

- Base URL: `https://gitlab.com`
- URL: `https://gitlab.com/api/v4/projects/{id}/ci/lint`
- Auth: none declared

Validates a provided CI/CD configuration in the context of a specified project.

## Path parameters

- `id` string, required

## Request body

- PostApiV4ProjectsIdCiLint: Validate a CI/CD configuration
  - `content` string, required: Content of .gitlab-ci.yml
  - `dry_run` boolean: Run pipeline creation simulation, or only do static check. This is false by default
  - `include_jobs` boolean: If the list of jobs that would exist in a static check or pipeline simulation should be included in the response. This is false by default
  - `ref` string: When dry_run is true, sets the branch or tag to use. Defaults to the project’s default branch when not set

## Response `200`

Validate a CI/CD configuration

- APIEntitiesCiLintResult: API_Entities_Ci_Lint_Result model
  - `valid` boolean, required
  - `errors` string[], required
  - `warnings` string[], required
  - `merged_yaml` string, required
  - `includes` APIEntitiesCiLintResultInclude[], required
    - `type` string, required
    - `location` string, required
    - `blob` string, required
    - `raw` string, required
    - `extra` object, required
    - `context_project` string, required
    - `context_sha` string, required
  - `jobs` object[]

---

[API](https://skmtc.dev/gitlab/apis/gitlab-api.md) - [All operations](https://skmtc.dev/gitlab/apis/gitlab-api/llms.txt) - [OpenAPI document](https://skmtc.dev/gitlab/apis/gitlab-api/revisions/b234947ef3f2?raw)
