Azure Pipelines Logs API

Operations for retrieving pipeline run execution logs for debugging, auditing, and monitoring purposes.

Business capability
Continuous Integration Management BC-4210.10

Operations 2

GET /pipelines/{pipelineId}/runs/{runId}/logs Azure Pipelines List pipeline run logs #
GET /pipelines/{pipelineId}/runs/{runId}/logs/{logId} Azure Pipelines Get a pipeline run log #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/microsoft-azure-pipelines-logs-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

microsoft-azure-pipelines-logs-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Azure Pipelines REST Logs API
  description: REST API for managing pipelines and pipeline runs in Azure DevOps. Provides programmatic access to create, list, and retrieve YAML-based CI/CD pipeline definitions, trigger and monitor pipeline runs with custom variables and parameters, access pipeline run logs for debugging and auditing, and retrieve artifacts produced by pipeline runs.
  version: '7.1'
  contact:
    name: Microsoft Azure DevOps
    url: https://learn.microsoft.com/en-us/rest/api/azure/devops/pipelines/
  termsOfService: https://azure.microsoft.com/en-us/support/legal/
servers:
- url: https://dev.azure.com/{organization}/{project}/_apis
  description: Azure DevOps Services
  variables:
    organization:
      description: Azure DevOps organization name or ID
      default: myorganization
    project:
      description: Azure DevOps project name or ID
      default: myproject
security:
- bearerAuth: []
- basicAuth: []
tags:
- name: Logs
  description: Operations for retrieving pipeline run execution logs for debugging, auditing, and monitoring purposes.
paths:
  /pipelines/{pipelineId}/runs/{runId}/logs:
    get:
      operationId: listLogs
      summary: Azure Pipelines List pipeline run logs
      description: Returns a list of log entries for a specific pipeline run. Each log entry represents output from a stage, job, or task in the pipeline execution. Use log IDs to retrieve detailed log content.
      tags:
      - Logs
      parameters:
      - $ref: '#/components/parameters/ApiVersion'
      - $ref: '#/components/parameters/PipelineId'
      - $ref: '#/components/parameters/RunId'
      - name: $expand
        in: query
        required: false
        description: Expand additional log details
        schema:
          type: string
          enum:
          - signedContent
      responses:
        '200':
          description: List of log entries returned successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  count:
                    type: integer
                    description: Number of log entries
                  value:
                    type: array
                    items:
                      $ref: '#/components/schemas/Log'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
  /pipelines/{pipelineId}/runs/{runId}/logs/{logId}:
    get:
      operationId: getLog
      summary: Azure Pipelines Get a pipeline run log
      description: Returns the content of a specific log from a pipeline run. The log content includes timestamped output from pipeline tasks, stages, and jobs. Useful for debugging failed runs and auditing pipeline execution.
      tags:
      - Logs
      parameters:
      - $ref: '#/components/parameters/ApiVersion'
      - $ref: '#/components/parameters/PipelineId'
      - $ref: '#/components/parameters/RunId'
      - name: logId
        in: path
        required: true
        description: Numeric ID of the log entry to retrieve
        schema:
          type: integer
      - name: $expand
        in: query
        required: false
        description: Expand additional log details
        schema:
          type: string
          enum:
          - signedContent
      responses:
        '200':
          description: Log content returned successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Log'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    NotFound:
      description: Not found - the requested resource does not exist
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    Forbidden:
      description: Forbidden - insufficient permissions to perform this operation
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
    Unauthorized:
      description: Unauthorized - missing or invalid authentication credentials
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiError'
  parameters:
    RunId:
      name: runId
      in: path
      required: true
      description: Numeric ID of the pipeline run
      schema:
        type: integer
    ApiVersion:
      name: api-version
      in: query
      required: true
      description: Azure DevOps REST API version. Use 7.1 for the latest stable version.
      schema:
        type: string
        default: '7.1'
        enum:
        - '7.1'
        - '7.0'
        - '6.0'
    PipelineId:
      name: pipelineId
      in: path
      required: true
      description: Numeric ID of the pipeline definition
      schema:
        type: integer
  schemas:
    Log:
      type: object
      description: A log entry from a pipeline run containing execution output from stages, jobs, or tasks.
      properties:
        id:
          type: integer
          description: Unique numeric identifier of the log entry
        createdOn:
          type: string
          format: date-time
          description: Timestamp when the log was created
        lastChangedOn:
          type: string
          format: date-time
          description: Timestamp when the log was last updated
        lineCount:
          type: integer
          description: Number of lines in the log
        url:
          type: string
          format: uri
          description: REST API URL to retrieve the log content
        signedContent:
          type: object
          description: Signed URL for secure log download
          properties:
            url:
              type: string
              format: uri
              description: Signed download URL
            signatureExpires:
              type: string
              format: date-time
              description: Expiration time of the signed URL
    ApiError:
      type: object
      description: Error response from the Azure DevOps API
      properties:
        id:
          type: string
          format: uuid
          description: Unique error instance identifier
        message:
          type: string
          description: Human-readable error message
        typeName:
          type: string
          description: Full type name of the error
        typeKey:
          type: string
          description: Error type key
        errorCode:
          type: integer
          description: Numeric error code
        eventId:
          type: integer
          description: Event identifier for tracking
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Azure AD OAuth 2.0 bearer token obtained through the authorization code flow with scope vso.build
    basicAuth:
      type: http
      scheme: basic
      description: Basic authentication using a Personal Access Token (PAT). Use any string as the username and the PAT as the password, then base64-encode the result.
externalDocs:
  description: Azure Pipelines REST API Documentation
  url: https://learn.microsoft.com/en-us/rest/api/azure/devops/pipelines/