{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/microsoft-azure-pipelines/json-schema/microsoft-azure-pipelines-pipeline-schema.json",
  "title": "Pipeline",
  "description": "An Azure DevOps pipeline definition representing a YAML-based CI/CD workflow stored in a source repository.",
  "x-generated": "2026-11-05",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/microsoft-azure-pipelines-pipelines-api-openapi.yml#/components/schemas/Pipeline",
  "type": "object",
  "properties": {
    "id": {
      "type": "integer",
      "description": "Unique numeric identifier of the pipeline"
    },
    "name": {
      "type": "string",
      "description": "Display name of the pipeline"
    },
    "folder": {
      "type": "string",
      "description": "Folder path for organizing pipelines in the project"
    },
    "revision": {
      "type": "integer",
      "description": "Current revision number of the pipeline definition"
    },
    "url": {
      "type": "string",
      "format": "uri",
      "description": "REST API URL to access this pipeline"
    },
    "_links": {
      "$ref": "#/$defs/ReferenceLinks"
    },
    "configuration": {
      "$ref": "#/$defs/PipelineConfiguration"
    }
  },
  "$defs": {
    "BuildRepository": {
      "type": "object",
      "description": "Repository configuration for a pipeline",
      "properties": {
        "id": {
          "type": "string",
          "description": "Repository identifier"
        },
        "name": {
          "type": "string",
          "description": "Repository name"
        },
        "type": {
          "type": "string",
          "description": "Repository type",
          "enum": [
            "TfsGit",
            "TfsVersionControl",
            "GitHub",
            "Bitbucket",
            "GitHubEnterprise"
          ]
        },
        "url": {
          "type": "string",
          "format": "uri",
          "description": "Repository URL"
        },
        "defaultBranch": {
          "type": "string",
          "description": "Default branch for the repository"
        }
      }
    },
    "PipelineConfiguration": {
      "type": "object",
      "description": "Configuration details specifying how a pipeline is defined including the type, YAML file path, and source repository.",
      "properties": {
        "type": {
          "type": "string",
          "description": "Pipeline configuration type",
          "enum": [
            "unknown",
            "yaml",
            "designerJson",
            "justInTime",
            "designerHyphenJson"
          ]
        },
        "path": {
          "type": "string",
          "description": "Path to the YAML pipeline file in the repository"
        },
        "repository": {
          "$ref": "#/$defs/BuildRepository"
        }
      }
    },
    "ReferenceLinks": {
      "type": "object",
      "description": "HAL links for navigating to related resources",
      "properties": {
        "self": {
          "type": "object",
          "properties": {
            "href": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "web": {
          "type": "object",
          "properties": {
            "href": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "pipeline": {
          "type": "object",
          "properties": {
            "href": {
              "type": "string",
              "format": "uri"
            }
          }
        },
        "pipeline.web": {
          "type": "object",
          "properties": {
            "href": {
              "type": "string",
              "format": "uri"
            }
          }
        }
      }
    }
  }
}