{
  "openapi": "3.1.0",
  "info": {
    "title": "Depot CI API",
    "description": "OpenAPI schema for the Depot CI Connect RPC API.",
    "version": "v1"
  },
  "servers": [
    {
      "url": "https://api.depot.dev"
    }
  ],
  "paths": {
    "/depot.ci.v1.CIService/CancelJob": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "CancelJob",
        "description": "Cancels a queued or running job.",
        "operationId": "CIService_CancelJob",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.CancelJobRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.CancelJobResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/CancelRun": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "CancelRun",
        "description": "Cancels a queued or running CI run and any of its unfinished workflows, jobs, and attempts.",
        "operationId": "CIService_CancelRun",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.CancelRunRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.CancelRunResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/CancelWorkflow": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "CancelWorkflow",
        "description": "Cancels a queued or running workflow and all its child jobs.",
        "operationId": "CIService_CancelWorkflow",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.CancelWorkflowRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.CancelWorkflowResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/DispatchWorkflow": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "DispatchWorkflow",
        "description": "Triggers a single workflow via workflow_dispatch, validating inputs against the workflow's schema.",
        "operationId": "CIService_DispatchWorkflow",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.DispatchWorkflowRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.DispatchWorkflowResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/ExportJobAttemptLogs": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "Exports a finite snapshot of persisted log lines.",
        "description": "A framed Connect/gRPC server stream (not a raw HTTP file download). Agents and API clients should call it with a generated client or protocol-aware decoder, read the first metadata response, then append each following chunk response to a file or writer in order. Use the Depot CLI `depot ci logs --output-file` when a shell-native file download is needed.",
        "operationId": "CIService_ExportJobAttemptLogs",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/connect+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/connect+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc-web": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc-web+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            },
            "application/grpc-web+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/connect+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/connect+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc-web": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc-web+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              },
              "application/grpc-web+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ExportJobAttemptLogsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/connect+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/connect+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetArtifactDownloadURL": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetArtifactDownloadURL",
        "description": "Returns a signed HTTPS URL for one artifact.",
        "operationId": "CIService_GetArtifactDownloadURL",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetArtifactDownloadURLRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetArtifactDownloadURLResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetAttempt": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetAttempt",
        "description": "Returns curated attempt metadata with parent job, workflow, and run context.",
        "operationId": "CIService_GetAttempt",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetAttemptRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetAttemptResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetFailureDiagnosis": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetFailureDiagnosis",
        "description": "Returns a bounded deterministic failure diagnosis for a run, workflow, job, or attempt.",
        "operationId": "CIService_GetFailureDiagnosis",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetFailureDiagnosisRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetFailureDiagnosisResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetJob": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetJob",
        "description": "Returns curated job metadata, parent run and workflow context, dependency summaries, and attempt history.",
        "operationId": "CIService_GetJob",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetJobRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetJobResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetJobAttemptLogs": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetJobAttemptLogs",
        "description": "Returns log lines for a job attempt.",
        "operationId": "CIService_GetJobAttemptLogs",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetJobAttemptLogsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetJobAttemptLogsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetJobAttemptMetrics": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetJobAttemptMetrics",
        "description": "Returns CPU and memory metrics for one job attempt.",
        "operationId": "CIService_GetJobAttemptMetrics",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetJobAttemptMetricsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetJobAttemptMetricsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetJobMetrics": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetJobMetrics",
        "description": "Returns per-attempt CPU and memory metric summaries for one job.",
        "operationId": "CIService_GetJobMetrics",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetJobMetricsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetJobMetricsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetJobSummary": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetJobSummary",
        "description": "Returns authored step summary markdown for a job, a specific attempt, or both.",
        "operationId": "CIService_GetJobSummary",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetJobSummaryRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetJobSummaryResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetRun": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetRun",
        "description": "Returns a CI run's identity, repo, trigger, status, and timestamps. For nested workflow, job, and attempt status, use `GetRunStatus`.",
        "operationId": "CIService_GetRun",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetRunRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetRunResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetRunMetrics": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetRunMetrics",
        "description": "Returns workflow, job, and attempt CPU and memory metric summaries for one run.",
        "operationId": "CIService_GetRunMetrics",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetRunMetricsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetRunMetricsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetRunStatus": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetRunStatus",
        "description": "Returns a CI run's status with its nested workflows, jobs, and attempts. For the run's identity, repo, trigger, and timestamps, use `GetRun`.",
        "operationId": "CIService_GetRunStatus",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetRunStatusRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetRunStatusResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/GetWorkflow": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "GetWorkflow",
        "description": "Returns curated workflow, run, execution, job, and attempt metadata for single-workflow inspection.",
        "operationId": "CIService_GetWorkflow",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.GetWorkflowRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.GetWorkflowResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/ListArtifacts": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "ListArtifacts",
        "description": "Returns CI artifact metadata for one run. Signed download URLs are not included.",
        "operationId": "CIService_ListArtifacts",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ListArtifactsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ListArtifactsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/ListRuns": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "ListRuns",
        "description": "Returns CI runs for the authenticated organization, newest first. Filter by status, repository, commit SHA, trigger, or pull request number. Use `pageSize` and `pageToken` to page through additional results.",
        "operationId": "CIService_ListRuns",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ListRunsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ListRunsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/ListWorkflows": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "ListWorkflows",
        "description": "Returns CI workflows for the authenticated organization, newest first. Filter by name, repository, status, trigger, commit SHA, or pull request number to find relevant workflows. Use page_size to return up to 200 workflows.",
        "operationId": "CIService_ListWorkflows",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.ListWorkflowsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.ListWorkflowsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/RerunWorkflow": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "RerunWorkflow",
        "description": "Resets all jobs in a finished workflow and re-runs them.",
        "operationId": "CIService_RerunWorkflow",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.RerunWorkflowRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.RerunWorkflowResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/RetryFailedJobs": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "RetryFailedJobs",
        "description": "Retries only failed and cancelled jobs (and their skipped dependents) in a finished workflow.",
        "operationId": "CIService_RetryFailedJobs",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.RetryFailedJobsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.RetryFailedJobsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/RetryJob": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "RetryJob",
        "description": "Retries a failed job within a running workflow.",
        "operationId": "CIService_RetryJob",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.RetryJobRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.RetryJobResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/Run": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "Run",
        "description": "Triggers a CI run. Runs can contain one or more workflows.",
        "operationId": "CIService_Run",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.RunRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.RunResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    },
    "/depot.ci.v1.CIService/StreamJobAttemptLogs": {
      "post": {
        "tags": [
          "CIService"
        ],
        "summary": "Follows persisted log lines for a job attempt.",
        "description": "A framed Connect/gRPC server stream (not a raw text response). Clients should consume response messages with a generated client or protocol-aware decoder. Each response includes the current attempt_status. Responses that carry a line also include next_cursor; persist that cursor and send it on a later request to resume after the emitted line.",
        "operationId": "CIService_StreamJobAttemptLogs",
        "parameters": [
          {
            "name": "Connect-Protocol-Version",
            "in": "header",
            "required": true,
            "schema": {
              "$ref": "#/components/schemas/connect-protocol-version"
            }
          },
          {
            "name": "Connect-Timeout-Ms",
            "in": "header",
            "schema": {
              "$ref": "#/components/schemas/connect-timeout-header"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/connect+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/connect+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc-web": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc-web+proto": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            },
            "application/grpc-web+json": {
              "schema": {
                "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Success",
            "content": {
              "application/connect+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/connect+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc-web": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc-web+proto": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              },
              "application/grpc-web+json": {
                "schema": {
                  "$ref": "#/components/schemas/depot.ci.v1.StreamJobAttemptLogsResponse"
                }
              }
            }
          },
          "default": {
            "description": "Error",
            "content": {
              "application/connect+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/connect+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web+proto": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              },
              "application/grpc-web+json": {
                "schema": {
                  "$ref": "#/components/schemas/connect.error"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "connect-protocol-version": {
        "type": "number",
        "title": "Connect-Protocol-Version",
        "enum": [
          1
        ],
        "description": "Define the version of the Connect protocol",
        "const": 1
      },
      "connect-timeout-header": {
        "type": "number",
        "title": "Connect-Timeout-Ms",
        "description": "Define the timeout, in ms"
      },
      "connect.error": {
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "examples": [
              "not_found"
            ],
            "enum": [
              "canceled",
              "unknown",
              "invalid_argument",
              "deadline_exceeded",
              "not_found",
              "already_exists",
              "permission_denied",
              "resource_exhausted",
              "failed_precondition",
              "aborted",
              "out_of_range",
              "unimplemented",
              "internal",
              "unavailable",
              "data_loss",
              "unauthenticated"
            ],
            "description": "The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code]."
          },
          "message": {
            "type": "string",
            "description": "A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client."
          },
          "details": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/connect.error_details.Any"
            },
            "description": "A list of messages that carry the error details. There is no limit on the number of messages."
          }
        },
        "title": "Connect Error",
        "additionalProperties": true,
        "description": "Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation"
      },
      "connect.error_details.Any": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "description": "A URL that acts as a globally unique identifier for the type of the serialized message. For example: `type.googleapis.com/google.rpc.ErrorInfo`. This is used to determine the schema of the data in the `value` field and is the discriminator for the `debug` field."
          },
          "value": {
            "type": "string",
            "format": "binary",
            "description": "The Protobuf message, serialized as bytes and base64-encoded. The specific message type is identified by the `type` field."
          },
          "debug": {
            "oneOf": [
              {
                "type": "object",
                "title": "Any",
                "additionalProperties": true,
                "description": "Detailed error information."
              }
            ],
            "discriminator": {
              "propertyName": "type"
            },
            "title": "Debug",
            "description": "Deserialized error detail payload. The 'type' field indicates the schema. This field is for easier debugging and should not be relied upon for application logic."
          }
        },
        "additionalProperties": true,
        "description": "Contains an arbitrary serialized message along with a @type that describes the type of the serialized message, with an additional debug field for ConnectRPC error details."
      },
      "depot.ci.v1.Artifact": {
        "type": "object",
        "properties": {
          "artifactId": {
            "type": "string",
            "title": "artifact_id",
            "description": "Unique identifier for the artifact. Used to request a download URL."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Parent workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the parent job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Parent job key from the workflow, for example \"build\" or \"test\"."
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt that produced the artifact."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number that produced the artifact, starting at 1."
          },
          "name": {
            "type": "string",
            "title": "name",
            "description": "Artifact name as authored by the workflow."
          },
          "sizeBytes": {
            "type": [
              "integer",
              "string"
            ],
            "title": "size_bytes",
            "format": "int64",
            "description": "Artifact size in bytes."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Artifact creation time, in RFC 3339 format."
          }
        },
        "title": "Artifact",
        "additionalProperties": false
      },
      "depot.ci.v1.AttemptStatus": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1 for the first run."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "sandboxId": {
            "type": "string",
            "title": "sandbox_id",
            "description": "Unique identifier for the sandbox currently running this attempt, when one exists."
          },
          "sessionId": {
            "type": "string",
            "title": "session_id",
            "description": "Unique identifier for the interactive session attached to that sandbox, when one is available."
          }
        },
        "title": "AttemptStatus",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricSample": {
        "type": "object",
        "properties": {
          "timestamp": {
            "type": "string",
            "title": "timestamp",
            "description": "Sample timestamp, in RFC 3339 format."
          },
          "cpuUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "cpu_utilization",
            "format": "double",
            "description": "CPU utilization as a fraction from 0 to 1. Unset when no CPU sample was recorded at this timestamp."
          },
          "memoryUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "memory_utilization",
            "format": "double",
            "description": "Memory utilization as a fraction from 0 to 1. Unset when no memory sample was recorded at this timestamp."
          },
          "memoryUsageBytes": {
            "type": [
              "integer",
              "string",
              "null"
            ],
            "title": "memory_usage_bytes",
            "format": "int64",
            "description": "Memory usage in bytes. Unset when no memory sample was recorded at this timestamp."
          }
        },
        "title": "CIMetricSample",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsAttemptContext": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1 for the first run."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the attempt, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the attempt concludes."
          },
          "sandboxId": {
            "type": "string",
            "title": "sandbox_id",
            "description": "Unique identifier for the sandbox that ran this attempt, when one exists."
          },
          "sessionId": {
            "type": "string",
            "title": "session_id",
            "description": "Unique identifier for the interactive session attached to that sandbox, when one is available."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Attempt creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Attempt start time, in RFC 3339 format. Empty until the attempt starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Attempt finish time, in RFC 3339 format. Empty until the attempt finishes."
          }
        },
        "title": "CIMetricsAttemptContext",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsAttemptMetrics": {
        "type": "object",
        "properties": {
          "attempt": {
            "title": "attempt",
            "description": "Attempt context: identifiers, status, conclusion, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAttemptContext"
          },
          "availability": {
            "title": "availability",
            "description": "Availability code and reason explaining why metrics are or are not present.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAvailability"
          },
          "stats": {
            "title": "stats",
            "description": "Aggregate CPU and memory statistics computed across the raw samples.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsStats"
          },
          "cap": {
            "title": "cap",
            "description": "Downsampling metadata describing how raw samples were reduced for transport.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsCapMetadata"
          },
          "samples": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.CIMetricSample"
            },
            "title": "samples",
            "description": "Time-ordered CPU and memory samples for the attempt, possibly downsampled."
          }
        },
        "title": "CIMetricsAttemptMetrics",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsAttemptSummary": {
        "type": "object",
        "properties": {
          "attempt": {
            "title": "attempt",
            "description": "Attempt context: identifiers, status, conclusion, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAttemptContext"
          },
          "availability": {
            "title": "availability",
            "description": "Availability code and reason explaining why metrics are or are not present.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAvailability"
          },
          "stats": {
            "title": "stats",
            "description": "Aggregate CPU and memory statistics computed across the raw samples.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsStats"
          },
          "cap": {
            "title": "cap",
            "description": "Downsampling metadata describing how raw samples were reduced for transport.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsCapMetadata"
          }
        },
        "title": "CIMetricsAttemptSummary",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsAvailability": {
        "type": "object",
        "properties": {
          "code": {
            "title": "code",
            "description": "Availability code.\n\n - AVAILABLE: metrics samples were observed for the attempt.\n - NO_SANDBOX: the attempt never ran on a sandbox, so no metrics could be collected.\n - NO_TIME_RANGE: the attempt has no resolvable start and finish time, so no metric window could be queried.\n - NO_SAMPLES: the attempt ran on a sandbox but no samples were recorded in its time range.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAvailabilityCode"
          },
          "reason": {
            "type": "string",
            "title": "reason",
            "description": "Short reason string matching the code, for example \"available\", \"no_sandbox\", \"no_time_range\", or \"no_samples\"."
          }
        },
        "title": "CIMetricsAvailability",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsAvailabilityCode": {
        "type": "string",
        "title": "CIMetricsAvailabilityCode",
        "enum": [
          "CI_METRICS_AVAILABILITY_CODE_UNSPECIFIED",
          "CI_METRICS_AVAILABILITY_CODE_AVAILABLE",
          "CI_METRICS_AVAILABILITY_CODE_NO_SANDBOX",
          "CI_METRICS_AVAILABILITY_CODE_NO_TIME_RANGE",
          "CI_METRICS_AVAILABILITY_CODE_NO_SAMPLES"
        ],
        "description": "Whether CPU and memory metrics are available for a job attempt, and if not, why.\n\n - AVAILABLE: metrics samples were observed for the attempt.\n - NO_SANDBOX: the attempt never ran on a sandbox, so no metrics could be collected.\n - NO_TIME_RANGE: the attempt has no resolvable start and finish time, so no metric window could be queried.\n - NO_SAMPLES: the attempt ran on a sandbox but no samples were recorded in its time range."
      },
      "depot.ci.v1.CIMetricsCapMetadata": {
        "type": "object",
        "properties": {
          "rawSampleCount": {
            "type": "integer",
            "title": "raw_sample_count",
            "description": "Raw sample count observed before downsampling."
          },
          "returnedSampleCount": {
            "type": "integer",
            "title": "returned_sample_count",
            "description": "Number of samples returned in the response."
          },
          "maxReturnedSampleCount": {
            "type": "integer",
            "title": "max_returned_sample_count",
            "description": "Hard cap on the number of samples a single response will return."
          },
          "downsampled": {
            "type": "boolean",
            "title": "downsampled",
            "description": "True when the raw samples were downsampled to fit max_returned_sample_count."
          },
          "downsampleStrategy": {
            "type": "string",
            "title": "downsample_strategy",
            "description": "Identifier for the downsampling strategy used, for example \"peak_preserving_even\". Empty when no downsampling was applied."
          }
        },
        "title": "CIMetricsCapMetadata",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsJobContext": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Job key from the workflow, for example \"build\" or \"test\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the job, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the job concludes."
          },
          "currentAttempt": {
            "type": "integer",
            "title": "current_attempt",
            "format": "int32",
            "description": "Most recent attempt number for this job. Zero until the first attempt is dispatched."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Job creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Job start time, in RFC 3339 format. Empty until the job starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Job finish time, in RFC 3339 format. Empty until the job finishes."
          }
        },
        "title": "CIMetricsJobContext",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsJobMetrics": {
        "type": "object",
        "properties": {
          "job": {
            "title": "job",
            "description": "Job context: identifiers, status, conclusion, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsJobContext"
          },
          "attempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAttemptSummary"
            },
            "title": "attempts",
            "description": "Per-attempt metric summaries for this job, ordered by attempt number ascending."
          }
        },
        "title": "CIMetricsJobMetrics",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsRunContext": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the run was triggered against. Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the run executes against. Empty for open pull_request runs."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Run creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Run start time, in RFC 3339 format. Empty until the run starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Run finish time, in RFC 3339 format. Empty until the run finishes."
          }
        },
        "title": "CIMetricsRunContext",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsStats": {
        "type": "object",
        "properties": {
          "sampleCount": {
            "type": "integer",
            "title": "sample_count",
            "description": "Total number of merged samples observed for the attempt."
          },
          "cpuSampleCount": {
            "type": "integer",
            "title": "cpu_sample_count",
            "description": "Number of samples that included a CPU utilization value."
          },
          "memorySampleCount": {
            "type": "integer",
            "title": "memory_sample_count",
            "description": "Number of samples that included a memory utilization value."
          },
          "peakCpuUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "peak_cpu_utilization",
            "format": "double",
            "description": "Peak observed CPU utilization as a fraction from 0 to 1. Unset when no CPU samples were observed."
          },
          "averageCpuUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "average_cpu_utilization",
            "format": "double",
            "description": "Average observed CPU utilization as a fraction from 0 to 1. Unset when no CPU samples were observed."
          },
          "peakMemoryUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "peak_memory_utilization",
            "format": "double",
            "description": "Peak observed memory utilization as a fraction from 0 to 1. Unset when no memory samples were observed."
          },
          "averageMemoryUtilization": {
            "type": [
              "number",
              "null"
            ],
            "title": "average_memory_utilization",
            "format": "double",
            "description": "Average observed memory utilization as a fraction from 0 to 1. Unset when no memory samples were observed."
          },
          "observedStartedAt": {
            "type": "string",
            "title": "observed_started_at",
            "description": "Timestamp of the first observed sample, in RFC 3339 format. Empty when no samples were observed."
          },
          "observedFinishedAt": {
            "type": "string",
            "title": "observed_finished_at",
            "description": "Timestamp of the last observed sample, in RFC 3339 format. Empty when no samples were observed."
          },
          "peakMemoryUsageBytes": {
            "type": [
              "integer",
              "string",
              "null"
            ],
            "title": "peak_memory_usage_bytes",
            "format": "int64",
            "description": "Peak observed memory usage in bytes. Unset when no memory samples were observed."
          },
          "averageMemoryUsageBytes": {
            "type": [
              "number",
              "null"
            ],
            "title": "average_memory_usage_bytes",
            "format": "double",
            "description": "Average observed memory usage in bytes. Unset when no memory samples were observed."
          }
        },
        "title": "CIMetricsStats",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsWorkflowContext": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "name": {
            "type": "string",
            "title": "name",
            "description": "Workflow name from the YAML `name:` key, falling back to the file path stem. Empty when not available."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Workflow creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Workflow start time, in RFC 3339 format. Empty until the workflow starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Workflow finish time, in RFC 3339 format. Empty until the workflow finishes."
          }
        },
        "title": "CIMetricsWorkflowContext",
        "additionalProperties": false
      },
      "depot.ci.v1.CIMetricsWorkflowMetrics": {
        "type": "object",
        "properties": {
          "workflow": {
            "title": "workflow",
            "description": "Workflow context: identifiers, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsWorkflowContext"
          },
          "jobs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.CIMetricsJobMetrics"
            },
            "title": "jobs",
            "description": "Jobs in the workflow and their per-attempt metric summaries."
          }
        },
        "title": "CIMetricsWorkflowMetrics",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelJobRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing the job."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job to cancel."
          }
        },
        "title": "CancelJobRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelJobResponse": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job. Matches the request job_id."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "New job status, typically \"cancelled\"."
          }
        },
        "title": "CancelJobResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelRunRequest": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Returned by `Run`, `DispatchWorkflow`, and `ListRuns`."
          }
        },
        "title": "CancelRunRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelRunResponse": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Matches the request `runId`."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "New run status, should be \"cancelled\"."
          }
        },
        "title": "CancelRunResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelWorkflowRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow to cancel."
          }
        },
        "title": "CancelWorkflowRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelWorkflowResponse": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow. Matches the request workflow_id."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "New workflow status, typically \"cancelled\"."
          }
        },
        "title": "CancelWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.DispatchWorkflowRequest": {
        "type": "object",
        "properties": {
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository to run against, in `owner/name` format, for example \"depot/cli\". Must be connected to your Depot organization through the Depot GitHub app."
          },
          "workflow": {
            "type": "string",
            "title": "workflow",
            "description": "Workflow file path, for example \".depot/workflows/deploy.yml\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Branch or tag name to run the workflow on, for example \"main\"."
          },
          "inputs": {
            "type": "object",
            "title": "inputs",
            "additionalProperties": {
              "type": "string",
              "title": "value"
            },
            "description": "Key-value pairs matching the workflow's input definitions. All values are strings; the server coerces each value to the input's declared type."
          }
        },
        "title": "DispatchWorkflowRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.DispatchWorkflowRequest.InputsEntry": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string",
            "title": "key"
          },
          "value": {
            "type": "string",
            "title": "value"
          }
        },
        "title": "InputsEntry",
        "additionalProperties": false
      },
      "depot.ci.v1.DispatchWorkflowResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this run."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the created CI run. Use it for run-scoped methods like `GetRun`, `GetRunStatus`, `CancelRun`, and `ListArtifacts` to track, cancel, or fetch results from the run."
          }
        },
        "title": "DispatchWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.DrillDownCommand": {
        "type": "object",
        "properties": {
          "kind": {
            "title": "kind",
            "description": "Kind of drill-down command.\n\n - LOGS: equivalent to `depot ci logs <attempt_id>`.\n - SUMMARY: equivalent to `depot ci summary <attempt_id>`.\n - DIAGNOSE_WORKFLOW: equivalent to `depot ci diagnose --workflow <workflow_id>`.\n - DIAGNOSE_JOB: equivalent to `depot ci diagnose --job <job_id>`.",
            "$ref": "#/components/schemas/depot.ci.v1.DrillDownCommandKind"
          },
          "argv": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "argv",
            "description": "Suggested command and arguments, for example [\"depot\", \"ci\", \"logs\", \"<attempt_id>\"]."
          },
          "targetId": {
            "type": "string",
            "title": "target_id",
            "description": "Unique identifier for the resource the command targets."
          },
          "label": {
            "type": "string",
            "title": "label",
            "description": "Human-readable label for the command, for example \"Logs\" or \"Diagnose workflow\"."
          }
        },
        "title": "DrillDownCommand",
        "additionalProperties": false
      },
      "depot.ci.v1.DrillDownCommandKind": {
        "type": "string",
        "title": "DrillDownCommandKind",
        "enum": [
          "DRILL_DOWN_COMMAND_KIND_UNSPECIFIED",
          "DRILL_DOWN_COMMAND_KIND_LOGS",
          "DRILL_DOWN_COMMAND_KIND_SUMMARY",
          "DRILL_DOWN_COMMAND_KIND_DIAGNOSE_WORKFLOW",
          "DRILL_DOWN_COMMAND_KIND_DIAGNOSE_JOB"
        ],
        "description": "Kind of drill-down a diagnosis suggests next. Maps to a Depot CLI subcommand in DrillDownCommand.argv.\n\n - LOGS: equivalent to `depot ci logs <attempt_id>`.\n - SUMMARY: equivalent to `depot ci summary <attempt_id>`.\n - DIAGNOSE_WORKFLOW: equivalent to `depot ci diagnose --workflow <workflow_id>`.\n - DIAGNOSE_JOB: equivalent to `depot ci diagnose --job <job_id>`."
      },
      "depot.ci.v1.ExportJobAttemptLogsRequest": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt. Set exactly one of attempt_id or job_id."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for a CI job. Export resolves it to that job's latest attempt at stream start. Set exactly one of attempt_id or job_id."
          },
          "format": {
            "title": "format",
            "description": "Selects the export byte format. Default: text.",
            "$ref": "#/components/schemas/depot.ci.v1.JobAttemptLogExportFormat"
          }
        },
        "title": "ExportJobAttemptLogsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.ExportJobAttemptLogsResponse": {
        "type": "object",
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "chunk": {
                "type": "string",
                "title": "chunk",
                "format": "byte",
                "description": "Export file bytes. Append chunks in stream order to reconstruct the text or JSONL export. In JSON-encoded Connect/grpc-web protocols, bytes are represented using the protocol's base64 encoding."
              }
            },
            "title": "chunk",
            "required": [
              "chunk"
            ]
          },
          {
            "type": "object",
            "properties": {
              "metadata": {
                "title": "metadata",
                "description": "First response in every successful export stream. Describes the byte format and advisory filename for following chunks.",
                "$ref": "#/components/schemas/depot.ci.v1.JobAttemptLogExportMetadata"
              }
            },
            "title": "metadata",
            "required": [
              "metadata"
            ]
          }
        ],
        "title": "ExportJobAttemptLogsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisBounds": {
        "type": "object",
        "properties": {
          "failedProblemCandidateCount": {
            "type": "integer",
            "title": "failed_problem_candidate_count",
            "description": "Number of failed problem candidates considered for the diagnosis."
          },
          "failedProblemCandidateCap": {
            "type": "integer",
            "title": "failed_problem_candidate_cap",
            "description": "Cap on failed problem candidates the diagnosis will examine before switching to over-limit."
          },
          "totalProblemJobCount": {
            "type": "integer",
            "title": "total_problem_job_count",
            "description": "Total number of jobs identified as problem candidates."
          },
          "skippedDependentCount": {
            "type": "integer",
            "title": "skipped_dependent_count",
            "description": "Number of jobs skipped because a failed dependency prevented them from running."
          },
          "totalFailureGroupCount": {
            "type": "integer",
            "title": "total_failure_group_count",
            "description": "Total number of distinct failure groups identified, before any cap."
          },
          "omittedFailureGroupCount": {
            "type": "integer",
            "title": "omitted_failure_group_count",
            "description": "Number of failure groups omitted because the response exceeded the group limit."
          },
          "failureGroupLimit": {
            "type": "integer",
            "title": "failure_group_limit",
            "description": "Maximum number of failure groups returned in a single response."
          },
          "representativesPerGroupLimit": {
            "type": "integer",
            "title": "representatives_per_group_limit",
            "description": "Maximum number of representative attempts returned per failure group."
          },
          "recentAttemptLimit": {
            "type": "integer",
            "title": "recent_attempt_limit",
            "description": "Maximum number of recent attempts considered for focused diagnoses."
          },
          "totalAttemptCount": {
            "type": "integer",
            "title": "total_attempt_count",
            "description": "Total number of attempts examined for the target. Populated for focused job diagnoses."
          },
          "omittedAttemptCount": {
            "type": "integer",
            "title": "omitted_attempt_count",
            "description": "Number of attempts omitted because the response exceeded the recent attempt limit."
          },
          "relevantLineLimit": {
            "type": "integer",
            "title": "relevant_line_limit",
            "description": "Maximum number of relevant log lines returned per representative attempt."
          },
          "errorLineBodyCharLimit": {
            "type": "integer",
            "title": "error_line_body_char_limit",
            "description": "Character cap applied to each relevant log line body."
          },
          "errorMessageCharLimit": {
            "type": "integer",
            "title": "error_message_char_limit",
            "description": "Character cap applied to error_message values in the response."
          },
          "contextLabelCharLimit": {
            "type": "integer",
            "title": "context_label_char_limit",
            "description": "Character cap applied to context label strings such as repo, ref, and workflow_name."
          },
          "overLimitWorkflowBreakdownLimit": {
            "type": "integer",
            "title": "over_limit_workflow_breakdown_limit",
            "description": "Maximum number of workflow breakdown rows returned in an over-limit response."
          },
          "overLimitJobBreakdownLimit": {
            "type": "integer",
            "title": "over_limit_job_breakdown_limit",
            "description": "Maximum number of job breakdown rows returned in an over-limit response."
          },
          "omittedWorkflowBreakdownCount": {
            "type": "integer",
            "title": "omitted_workflow_breakdown_count",
            "description": "Number of workflow breakdown rows omitted because they exceeded the limit."
          },
          "omittedJobBreakdownCount": {
            "type": "integer",
            "title": "omitted_job_breakdown_count",
            "description": "Number of job breakdown rows omitted because they exceeded the limit."
          },
          "truncated": {
            "type": "boolean",
            "title": "truncated",
            "description": "True when any part of the response was truncated to fit the limits above."
          }
        },
        "title": "FailureDiagnosisBounds",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisBreakdownRow": {
        "type": "object",
        "properties": {
          "targetType": {
            "title": "target_type",
            "description": "Resource type for target_id, for example workflow or job.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisTargetType"
          },
          "targetId": {
            "type": "string",
            "title": "target_id",
            "description": "Unique identifier for the resource this row describes."
          },
          "label": {
            "type": "string",
            "title": "label",
            "description": "Human-readable label for the resource, for example a workflow name or job key."
          },
          "status": {
            "title": "status",
            "description": "Current state of the resource.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "failedProblemCandidateCount": {
            "type": "integer",
            "title": "failed_problem_candidate_count",
            "description": "Number of failed problem candidates attributed to this resource."
          },
          "nextCommands": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.DrillDownCommand"
            },
            "title": "next_commands",
            "description": "Drill-down commands suggested for this resource."
          }
        },
        "title": "FailureDiagnosisBreakdownRow",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisCommandCapabilities": {
        "type": "object",
        "properties": {
          "summaryCommandAvailable": {
            "type": "boolean",
            "title": "summary_command_available",
            "description": "True when the summary drill-down command is available for this diagnosis."
          }
        },
        "title": "FailureDiagnosisCommandCapabilities",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisConclusion": {
        "type": "string",
        "title": "FailureDiagnosisConclusion",
        "enum": [
          "FAILURE_DIAGNOSIS_CONCLUSION_UNSPECIFIED",
          "FAILURE_DIAGNOSIS_CONCLUSION_SUCCESS",
          "FAILURE_DIAGNOSIS_CONCLUSION_FAILURE",
          "FAILURE_DIAGNOSIS_CONCLUSION_CANCELLED",
          "FAILURE_DIAGNOSIS_CONCLUSION_SKIPPED",
          "FAILURE_DIAGNOSIS_CONCLUSION_TIMED_OUT"
        ],
        "description": "Final outcome of a job or attempt referenced by a diagnosis."
      },
      "depot.ci.v1.FailureDiagnosisContext": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the run was triggered against. Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the run executes against. Empty for open pull_request runs."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "runStatus": {
            "title": "run_status",
            "description": "Current state of the parent run.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow. Empty when the target is a run."
          },
          "workflowName": {
            "type": "string",
            "title": "workflow_name",
            "description": "Parent workflow name from the YAML `name:` key, falling back to the file path stem. Empty when not available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Parent workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request, or when the target is a run."
          },
          "workflowStatus": {
            "title": "workflow_status",
            "description": "Current state of the parent workflow.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the parent job. Empty when the target is a run or workflow."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Parent job key from the workflow. Empty when the target is a run or workflow."
          },
          "jobDisplayName": {
            "type": "string",
            "title": "job_display_name",
            "description": "Human-readable display name for the parent job, falling back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "title": "job_status",
            "description": "Current state of the parent job.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "jobConclusion": {
            "title": "job_conclusion",
            "description": "Conclusion of the parent job. Unspecified until the job concludes.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisConclusion"
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the parent attempt. Empty unless the target is an attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number for the parent attempt. Zero unless the target is an attempt."
          },
          "attemptStatus": {
            "title": "attempt_status",
            "description": "Current state of the parent attempt.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "attemptConclusion": {
            "title": "attempt_conclusion",
            "description": "Conclusion of the parent attempt. Unspecified until the attempt concludes.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisConclusion"
          },
          "truncatedContextFields": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "truncated_context_fields",
            "description": "Names of context fields that were truncated to fit the response limits."
          }
        },
        "title": "FailureDiagnosisContext",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisEmptyReason": {
        "type": "string",
        "title": "FailureDiagnosisEmptyReason",
        "enum": [
          "FAILURE_DIAGNOSIS_EMPTY_REASON_UNSPECIFIED",
          "FAILURE_DIAGNOSIS_EMPTY_REASON_NO_FAILURE_EVIDENCE"
        ],
        "description": "Reason a diagnosis was returned in the EMPTY state."
      },
      "depot.ci.v1.FailureDiagnosisResourceStatus": {
        "type": "string",
        "title": "FailureDiagnosisResourceStatus",
        "enum": [
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_UNSPECIFIED",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_QUEUED",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_WAITING",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_RUNNING",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_FINISHED",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_FAILED",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_CANCELLED",
          "FAILURE_DIAGNOSIS_RESOURCE_STATUS_SKIPPED"
        ],
        "description": "Lifecycle state of a run, workflow, job, or attempt referenced by a diagnosis.\n\n - QUEUED: waiting in the queue to be dispatched.\n - WAITING: waiting on dependencies before it can be dispatched. Applies to jobs.\n - RUNNING: currently executing.\n - FINISHED: completed without failure or cancellation.\n - FAILED: stopped because of an error.\n - CANCELLED: cancelled before it finished, either by a user or by a parent's cancellation.\n - SKIPPED: skipped because of an unmet condition or a failed dependency. Applies to jobs and attempts."
      },
      "depot.ci.v1.FailureDiagnosisState": {
        "type": "string",
        "title": "FailureDiagnosisState",
        "enum": [
          "FAILURE_DIAGNOSIS_STATE_UNSPECIFIED",
          "FAILURE_DIAGNOSIS_STATE_EMPTY",
          "FAILURE_DIAGNOSIS_STATE_GROUPED_FAILURES",
          "FAILURE_DIAGNOSIS_STATE_FOCUSED_FAILURE",
          "FAILURE_DIAGNOSIS_STATE_OVER_LIMIT"
        ],
        "description": "Overall shape of the failure diagnosis response.\n\n - EMPTY: no failure evidence was found; failure_groups and representative_attempts are empty.\n - GROUPED_FAILURES: failures bucketed by fingerprint into failure_groups. Returned for run and workflow targets.\n - FOCUSED_FAILURE: diagnosis focuses on a single job or attempt. Returned for job and attempt targets.\n - OVER_LIMIT: too many failed candidates to diagnose individually; over_limit_breakdown lists per-workflow and per-job counts instead."
      },
      "depot.ci.v1.FailureDiagnosisTarget": {
        "type": "object",
        "properties": {
          "targetId": {
            "type": "string",
            "title": "target_id",
            "description": "Unique identifier for the diagnosed resource."
          },
          "targetType": {
            "title": "target_type",
            "description": "Resource type for target_id: run, workflow, job, or attempt.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisTargetType"
          },
          "status": {
            "title": "status",
            "description": "Current state of the target resource.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          }
        },
        "title": "FailureDiagnosisTarget",
        "additionalProperties": false
      },
      "depot.ci.v1.FailureDiagnosisTargetType": {
        "type": "string",
        "title": "FailureDiagnosisTargetType",
        "enum": [
          "FAILURE_DIAGNOSIS_TARGET_TYPE_UNSPECIFIED",
          "FAILURE_DIAGNOSIS_TARGET_TYPE_RUN",
          "FAILURE_DIAGNOSIS_TARGET_TYPE_WORKFLOW",
          "FAILURE_DIAGNOSIS_TARGET_TYPE_JOB",
          "FAILURE_DIAGNOSIS_TARGET_TYPE_ATTEMPT"
        ],
        "description": "Resource kind a failure diagnosis can target."
      },
      "depot.ci.v1.FailureGroup": {
        "type": "object",
        "properties": {
          "fingerprint": {
            "type": "string",
            "title": "fingerprint",
            "description": "Stable identifier for this failure group, derived from a normalized fingerprint of the error."
          },
          "source": {
            "type": "string",
            "title": "source",
            "description": "Origin of the error text used to form the fingerprint, for example \"attempt_error\", \"job_error\", \"workflow_error\", or \"status\"."
          },
          "count": {
            "type": "integer",
            "title": "count",
            "description": "Number of candidate attempts that fell into this group."
          },
          "errorMessage": {
            "type": "string",
            "title": "error_message",
            "description": "Representative error message for the group, possibly truncated."
          },
          "errorMessageTruncated": {
            "type": "boolean",
            "title": "error_message_truncated",
            "description": "True when error_message was truncated to fit the response limit."
          },
          "errorMessageOriginalLength": {
            "type": "integer",
            "title": "error_message_original_length",
            "description": "Original length of error_message before truncation."
          },
          "diagnosis": {
            "type": "string",
            "title": "diagnosis",
            "description": "AI-generated diagnosis summarizing the failure. Empty when no diagnosis is available."
          },
          "possibleFix": {
            "type": "string",
            "title": "possible_fix",
            "description": "AI-generated suggested fix. Empty when no suggestion is available."
          },
          "representatives": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.RepresentativeAttempt"
            },
            "title": "representatives",
            "description": "Representative attempts for the group, capped by the per-group limit."
          },
          "omittedRepresentativeCount": {
            "type": "integer",
            "title": "omitted_representative_count",
            "description": "Number of additional candidate attempts omitted from representatives."
          }
        },
        "title": "FailureGroup",
        "additionalProperties": false
      },
      "depot.ci.v1.GetArtifactDownloadURLRequest": {
        "type": "object",
        "properties": {
          "artifactId": {
            "type": "string",
            "title": "artifact_id",
            "description": "Unique identifier for the artifact, as returned by ListArtifacts."
          }
        },
        "title": "GetArtifactDownloadURLRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetArtifactDownloadURLResponse": {
        "type": "object",
        "properties": {
          "artifact": {
            "title": "artifact",
            "description": "Artifact metadata matching the requested artifact_id.",
            "$ref": "#/components/schemas/depot.ci.v1.Artifact"
          },
          "url": {
            "type": "string",
            "title": "url",
            "description": "Short-lived signed HTTPS bearer URL for the artifact object. Clients can use it with any standard HTTPS client while the object remains available."
          },
          "expiresAt": {
            "type": "string",
            "title": "expires_at",
            "description": "Signed URL expiration time (not artifact retention)."
          }
        },
        "title": "GetArtifactDownloadURLResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetAttemptRequest": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          }
        },
        "title": "GetAttemptRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetAttemptResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this attempt."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the parent run was triggered against. Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the parent run executes against. For pull_request triggers, the merge commit SHA."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the parent run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "runStatus": {
            "type": "string",
            "title": "run_status",
            "description": "Current state of the parent run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "runCreatedAt": {
            "type": "string",
            "title": "run_created_at",
            "description": "Parent run creation time, in RFC 3339 format."
          },
          "runStartedAt": {
            "type": "string",
            "title": "run_started_at",
            "description": "Parent run start time, in RFC 3339 format. Empty until the run starts."
          },
          "runFinishedAt": {
            "type": "string",
            "title": "run_finished_at",
            "description": "Parent run finish time, in RFC 3339 format. Empty until the run finishes."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow."
          },
          "workflowName": {
            "type": "string",
            "title": "workflow_name",
            "description": "Parent workflow name from the YAML `name:` key, falling back to the file path stem. Empty when neither is available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Parent workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "workflowStatus": {
            "type": "string",
            "title": "workflow_status",
            "description": "Current state of the parent workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "workflowErrorMessage": {
            "type": "string",
            "title": "workflow_error_message",
            "description": "Parent workflow error or cancellation reason, for example a compilation or validation error. Empty when the workflow is healthy."
          },
          "workflowCreatedAt": {
            "type": "string",
            "title": "workflow_created_at",
            "description": "Parent workflow creation time, in RFC 3339 format."
          },
          "workflowStartedAt": {
            "type": "string",
            "title": "workflow_started_at",
            "description": "Parent workflow start time, in RFC 3339 format. Empty until the workflow starts."
          },
          "workflowFinishedAt": {
            "type": "string",
            "title": "workflow_finished_at",
            "description": "Parent workflow finish time, in RFC 3339 format. Empty until the workflow finishes."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the parent job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Parent job key from the workflow, for example \"build\" or \"test\"."
          },
          "jobDisplayName": {
            "type": "string",
            "title": "job_display_name",
            "description": "Human-readable display name for the parent job, falling back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "type": "string",
            "title": "job_status",
            "description": "Current state of the parent job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "jobConclusion": {
            "type": "string",
            "title": "job_conclusion",
            "description": "Conclusion of the parent job, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the job concludes."
          },
          "jobErrorMessage": {
            "type": "string",
            "title": "job_error_message",
            "description": "Parent job error message populated for orchestration or worker failures. Empty when the job has no error."
          },
          "jobCreatedAt": {
            "type": "string",
            "title": "job_created_at",
            "description": "Parent job creation time, in RFC 3339 format."
          },
          "jobDispatchedAt": {
            "type": "string",
            "title": "job_dispatched_at",
            "description": "Parent job dispatch time, in RFC 3339 format. Empty until the job is dispatched to a worker."
          },
          "jobStartedAt": {
            "type": "string",
            "title": "job_started_at",
            "description": "Parent job start time, in RFC 3339 format. Empty until the job starts."
          },
          "jobFinishedAt": {
            "type": "string",
            "title": "job_finished_at",
            "description": "Parent job finish time, in RFC 3339 format. Empty until the job finishes."
          },
          "currentAttemptId": {
            "type": "string",
            "title": "current_attempt_id",
            "description": "Unique identifier for the parent job's most recent attempt. Equals attempt.attempt_id when this is the current attempt."
          },
          "currentAttempt": {
            "type": "integer",
            "title": "current_attempt",
            "format": "int32",
            "description": "Most recent attempt number for the parent job. Equals attempt.attempt when this is the current attempt."
          },
          "matrix": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobDetailMatrixValue"
            },
            "title": "matrix",
            "description": "Matrix key/value pairs for the parent job instance. Empty when the job is not part of a matrix strategy."
          },
          "strategy": {
            "title": "strategy",
            "description": "Strategy context exposing the parent job's index within its matrix expansion. Unset when no strategy context is available.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailStrategy"
          },
          "runsOn": {
            "title": "runs_on",
            "description": "Resolved runner configuration for the parent job: labels, image, CPU, memory, and size. Unset when no runner could be resolved for the parent job.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailRunsOn"
          },
          "attempt": {
            "title": "attempt",
            "description": "The requested attempt's identifiers, lifecycle timestamps, conclusion, and sandbox/session linkage.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailAttempt"
          }
        },
        "title": "GetAttemptResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetFailureDiagnosisRequest": {
        "type": "object",
        "properties": {
          "targetId": {
            "type": "string",
            "title": "target_id",
            "description": "Unique identifier for the requested CI run, workflow, job, or attempt."
          },
          "targetType": {
            "title": "target_type",
            "description": "Resource type for target_id: run, workflow, job, or attempt.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisTargetType"
          }
        },
        "title": "GetFailureDiagnosisRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetFailureDiagnosisResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns the diagnosed resource."
          },
          "target": {
            "title": "target",
            "description": "The resource the diagnosis was requested for: run, workflow, job, or attempt.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisTarget"
          },
          "context": {
            "title": "context",
            "description": "Resolved parent context for the target, with identifiers, statuses, and conclusions.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisContext"
          },
          "state": {
            "title": "state",
            "description": "Overall diagnosis state.\n\n - EMPTY: no failure evidence was found; failure_groups and representative_attempts are empty.\n - GROUPED_FAILURES: failures bucketed by fingerprint into failure_groups. Returned for run and workflow targets.\n - FOCUSED_FAILURE: diagnosis focuses on a single job or attempt. Returned for job and attempt targets.\n - OVER_LIMIT: too many failed candidates to diagnose individually; over_limit_breakdown lists per-workflow and per-job counts instead.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisState"
          },
          "emptyReason": {
            "title": "empty_reason",
            "description": "Reason the diagnosis is empty when state is empty. Unspecified otherwise.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisEmptyReason"
          },
          "failureGroups": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.FailureGroup"
            },
            "title": "failure_groups",
            "description": "Failures grouped by deterministic error fingerprint. Empty when state is empty or over limit."
          },
          "representativeAttempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.RepresentativeAttempt"
            },
            "title": "representative_attempts",
            "description": "Flat list of representative attempts across failure groups, for clients that don't traverse groups."
          },
          "bounds": {
            "title": "bounds",
            "description": "Limits and counts that describe how the diagnosis was bounded or truncated.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisBounds"
          },
          "nextCommands": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.DrillDownCommand"
            },
            "title": "next_commands",
            "description": "Top-level drill-down commands suggested for the target, for example \"depot ci logs\" or \"depot ci diagnose\"."
          },
          "commandCapabilities": {
            "title": "command_capabilities",
            "description": "Optional capabilities that gate which drill-down commands clients should surface.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisCommandCapabilities"
          },
          "overLimitBreakdown": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisBreakdownRow"
            },
            "title": "over_limit_breakdown",
            "description": "Workflow and job breakdown rows returned when the diagnosis exceeds the candidate cap. Empty for other states."
          }
        },
        "title": "GetFailureDiagnosisResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobAttemptLogsRequest": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          },
          "pageToken": {
            "type": "string",
            "title": "page_token",
            "description": "Resumes cursor pagination from a previous response."
          },
          "jobId": {
            "type": [
              "string",
              "null"
            ],
            "title": "job_id",
            "description": "Unique identifier for a CI job. Resolves to the job's latest attempt."
          }
        },
        "title": "GetJobAttemptLogsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobAttemptLogsResponse": {
        "type": "object",
        "properties": {
          "lines": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.LogLine"
            },
            "title": "lines",
            "description": "Persisted log lines for the attempt, in stream order."
          },
          "nextPageToken": {
            "type": "string",
            "title": "next_page_token",
            "description": "Token to retrieve the next page of results; empty if no more pages."
          }
        },
        "title": "GetJobAttemptLogsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobAttemptMetricsRequest": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          }
        },
        "title": "GetJobAttemptMetricsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobAttemptMetricsResponse": {
        "type": "object",
        "properties": {
          "run": {
            "title": "run",
            "description": "Parent run context: identifiers, trigger, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsRunContext"
          },
          "workflow": {
            "title": "workflow",
            "description": "Parent workflow context: identifiers, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsWorkflowContext"
          },
          "job": {
            "title": "job",
            "description": "Parent job context: identifiers, status, conclusion, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsJobContext"
          },
          "attempt": {
            "title": "attempt",
            "description": "Attempt-level metrics: attempt context, availability, summary stats, downsampling metadata, and raw samples.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAttemptMetrics"
          },
          "snapshotAt": {
            "type": "string",
            "title": "snapshot_at",
            "description": "Server time at which this metrics snapshot was captured, in RFC 3339 format. For attempts that haven't finished yet, CPU and memory data is collected up to this time, so a running attempt's metrics grow on successive calls."
          }
        },
        "title": "GetJobAttemptMetricsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobMetricsRequest": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          }
        },
        "title": "GetJobMetricsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobMetricsResponse": {
        "type": "object",
        "properties": {
          "run": {
            "title": "run",
            "description": "Parent run context: identifiers, trigger, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsRunContext"
          },
          "workflow": {
            "title": "workflow",
            "description": "Parent workflow context: identifiers, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsWorkflowContext"
          },
          "job": {
            "title": "job",
            "description": "Job context: identifiers, status, conclusion, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsJobContext"
          },
          "attempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.CIMetricsAttemptSummary"
            },
            "title": "attempts",
            "description": "Per-attempt metric summaries for this job, ordered by attempt number ascending."
          },
          "snapshotAt": {
            "type": "string",
            "title": "snapshot_at",
            "description": "Server time at which this metrics snapshot was captured, in RFC 3339 format. For attempts that haven't finished yet, CPU and memory data is collected up to this time, so a running attempt's metrics grow on successive calls."
          }
        },
        "title": "GetJobMetricsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobRequest": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          }
        },
        "title": "GetJobRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this job."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the parent run was triggered against. Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the parent run executes against. For pull_request triggers, the merge commit SHA."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the parent run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "runStatus": {
            "type": "string",
            "title": "run_status",
            "description": "Current state of the parent run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "runCreatedAt": {
            "type": "string",
            "title": "run_created_at",
            "description": "Parent run creation time, in RFC 3339 format."
          },
          "runStartedAt": {
            "type": "string",
            "title": "run_started_at",
            "description": "Parent run start time, in RFC 3339 format. Empty until the run starts."
          },
          "runFinishedAt": {
            "type": "string",
            "title": "run_finished_at",
            "description": "Parent run finish time, in RFC 3339 format. Empty until the run finishes."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow."
          },
          "workflowName": {
            "type": "string",
            "title": "workflow_name",
            "description": "Parent workflow name from the YAML `name:` key, falling back to the file path stem. Empty when neither is available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Parent workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "workflowStatus": {
            "type": "string",
            "title": "workflow_status",
            "description": "Current state of the parent workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "workflowErrorMessage": {
            "type": "string",
            "title": "workflow_error_message",
            "description": "Parent workflow error or cancellation reason, for example a compilation or validation error. Empty when the workflow is healthy."
          },
          "workflowCreatedAt": {
            "type": "string",
            "title": "workflow_created_at",
            "description": "Parent workflow creation time, in RFC 3339 format."
          },
          "workflowStartedAt": {
            "type": "string",
            "title": "workflow_started_at",
            "description": "Parent workflow start time, in RFC 3339 format. Empty until the workflow starts."
          },
          "workflowFinishedAt": {
            "type": "string",
            "title": "workflow_finished_at",
            "description": "Parent workflow finish time, in RFC 3339 format. Empty until the workflow finishes."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Job key from the workflow, for example \"build\" or \"test\"."
          },
          "jobDisplayName": {
            "type": "string",
            "title": "job_display_name",
            "description": "Human-readable display name from the workflow, falling back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "type": "string",
            "title": "job_status",
            "description": "Current state of the job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "jobConclusion": {
            "type": "string",
            "title": "job_conclusion",
            "description": "Conclusion of the job, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the job concludes."
          },
          "jobErrorMessage": {
            "type": "string",
            "title": "job_error_message",
            "description": "Job error message populated for orchestration or worker failures. Empty when the job has no error."
          },
          "jobCreatedAt": {
            "type": "string",
            "title": "job_created_at",
            "description": "Job creation time, in RFC 3339 format."
          },
          "jobDispatchedAt": {
            "type": "string",
            "title": "job_dispatched_at",
            "description": "Job dispatch time, in RFC 3339 format. Empty until the job is dispatched to a worker."
          },
          "jobStartedAt": {
            "type": "string",
            "title": "job_started_at",
            "description": "Job start time, in RFC 3339 format. Empty until the job starts."
          },
          "jobFinishedAt": {
            "type": "string",
            "title": "job_finished_at",
            "description": "Job finish time, in RFC 3339 format. Empty until the job finishes."
          },
          "currentAttemptId": {
            "type": "string",
            "title": "current_attempt_id",
            "description": "Unique identifier for the most recent attempt for this job. Empty until the first attempt is dispatched."
          },
          "currentAttempt": {
            "type": "integer",
            "title": "current_attempt",
            "format": "int32",
            "description": "Most recent attempt number for this job. Zero until the first attempt is dispatched."
          },
          "matrix": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobDetailMatrixValue"
            },
            "title": "matrix",
            "description": "Matrix key/value pairs for this job instance. Empty when the job is not part of a matrix strategy."
          },
          "strategy": {
            "title": "strategy",
            "description": "Strategy context exposing this job's index within its matrix expansion. Unset when no strategy context is available.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailStrategy"
          },
          "runsOn": {
            "title": "runs_on",
            "description": "Resolved runner configuration: labels, image, CPU, memory, and size. Unset when no runner could be resolved for the job.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailRunsOn"
          },
          "dependencies": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobDetailDependency"
            },
            "title": "dependencies",
            "description": "Every dependency for small jobs. For jobs with many dependencies, the list is a prioritized preview."
          },
          "attempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobDetailAttempt"
            },
            "title": "attempts",
            "description": "Attempt history for this job, ordered by attempt number ascending."
          },
          "dependencyCount": {
            "type": [
              "integer",
              "null"
            ],
            "title": "dependency_count",
            "format": "int32",
            "description": "Total dependency count, set only when dependencies is a capped preview."
          },
          "dependencyPreviewLimit": {
            "type": [
              "integer",
              "null"
            ],
            "title": "dependency_preview_limit",
            "format": "int32",
            "description": "Preview cap on dependencies, set only when dependencies is a capped preview."
          }
        },
        "title": "GetJobResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobSummaryRequest": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job whose current attempt should be summarized. Required unless attempt_id is set."
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for a specific job attempt to summarize. Required unless job_id is set. When sent alongside job_id, the attempt must belong to that job."
          }
        },
        "title": "GetJobSummaryRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobSummaryResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this job."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt. Empty when no attempt exists yet."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1. Zero when no attempt exists yet."
          },
          "jobStatus": {
            "type": "string",
            "title": "job_status",
            "description": "Current state of the job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "attemptStatus": {
            "type": "string",
            "title": "attempt_status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\". Empty when no attempt exists yet."
          },
          "hasSummary": {
            "type": "boolean",
            "title": "has_summary",
            "description": "True when authored step summary markdown is available for the selected attempt."
          },
          "emptyReason": {
            "type": "string",
            "title": "empty_reason",
            "description": "Set when has_summary is false, for example \"no_summary\" or \"no_attempt\"."
          },
          "stepCount": {
            "type": "integer",
            "title": "step_count",
            "description": "Count of non-empty step summaries included in markdown."
          },
          "markdown": {
            "type": "string",
            "title": "markdown",
            "description": "Authored step summary markdown joined in step order."
          }
        },
        "title": "GetJobSummaryResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunMetricsRequest": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Returned by `Run`, `DispatchWorkflow`, and `ListRuns`."
          }
        },
        "title": "GetRunMetricsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunMetricsResponse": {
        "type": "object",
        "properties": {
          "run": {
            "title": "run",
            "description": "Run context: identifiers, trigger, status, and lifecycle timestamps.",
            "$ref": "#/components/schemas/depot.ci.v1.CIMetricsRunContext"
          },
          "workflows": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.CIMetricsWorkflowMetrics"
            },
            "title": "workflows",
            "description": "Per-workflow rollups containing each workflow's jobs and per-attempt metric summaries."
          },
          "snapshotAt": {
            "type": "string",
            "title": "snapshot_at",
            "description": "Server time at which this metrics snapshot was captured, in RFC 3339 format. For attempts that haven't finished yet, CPU and memory data is collected up to this time, so a running attempt's metrics grow on successive calls."
          }
        },
        "title": "GetRunMetricsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunRequest": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Returned by `Run`, `DispatchWorkflow`, and `ListRuns`."
          }
        },
        "title": "GetRunRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this run."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the run was triggered against, for example \"refs/heads/main\" or \"refs/pull/42/merge\". Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the run executes against. Empty for open pull_request runs; populated with the merge commit SHA once the PR is closed and merged."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers; matches the PR or merge group head. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Start time, in RFC 3339 format. Empty until the run starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Finish time, in RFC 3339 format. Empty until the run finishes."
          }
        },
        "title": "GetRunResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunStatusRequest": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Returned by `Run`, `DispatchWorkflow`, and `ListRuns`."
          }
        },
        "title": "GetRunStatusRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetRunStatusResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this run."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "workflows": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.WorkflowStatus"
            },
            "title": "workflows",
            "description": "Workflows in the run with their nested jobs and attempts."
          }
        },
        "title": "GetRunStatusResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetWorkflowExecution": {
        "type": "object",
        "properties": {
          "executionId": {
            "type": "string",
            "title": "execution_id",
            "description": "Unique identifier for the workflow execution."
          },
          "execution": {
            "type": "integer",
            "title": "execution",
            "format": "int32",
            "description": "Execution number, starting at 1 for the first execution."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the execution, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Execution creation time, in RFC 3339 format."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Execution start time, in RFC 3339 format. Empty until the execution starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Execution finish time, in RFC 3339 format. Empty until the execution finishes."
          }
        },
        "title": "GetWorkflowExecution",
        "additionalProperties": false,
        "description": "GetWorkflowExecution describes one workflow execution/re-run."
      },
      "depot.ci.v1.GetWorkflowJob": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Job key from the workflow, for example \"build\" or \"test\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Job start time, in RFC 3339 format. Empty until the job starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Job finish time, in RFC 3339 format. Empty until the job finishes."
          },
          "attempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.GetWorkflowJobAttempt"
            },
            "title": "attempts",
            "description": "Per-job attempts, not workflow execution records."
          }
        },
        "title": "GetWorkflowJob",
        "additionalProperties": false
      },
      "depot.ci.v1.GetWorkflowJobAttempt": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1 for the first run."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "sandboxId": {
            "type": "string",
            "title": "sandbox_id",
            "description": "Unique identifier for the sandbox currently running this attempt, when one exists."
          },
          "sessionId": {
            "type": "string",
            "title": "session_id",
            "description": "Unique identifier for the interactive session attached to that sandbox, when one is available."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Attempt start time, in RFC 3339 format. Empty until the attempt starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Attempt finish time, in RFC 3339 format. Empty until the attempt finishes."
          }
        },
        "title": "GetWorkflowJobAttempt",
        "additionalProperties": false,
        "description": "GetWorkflowJobAttempt describes one attempt of a job returned by GetWorkflow."
      },
      "depot.ci.v1.GetWorkflowRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow."
          }
        },
        "title": "GetWorkflowRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetWorkflowResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this workflow."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the parent run was triggered against. Empty when the trigger carries no ref."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the parent run executes against. For pull_request triggers, the merge commit SHA."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the parent run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "runStatus": {
            "type": "string",
            "title": "run_status",
            "description": "Current state of the parent run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "runCreatedAt": {
            "type": "string",
            "title": "run_created_at",
            "description": "Parent run creation time, in RFC 3339 format."
          },
          "runStartedAt": {
            "type": "string",
            "title": "run_started_at",
            "description": "Parent run start time, in RFC 3339 format. Empty until the run starts."
          },
          "runFinishedAt": {
            "type": "string",
            "title": "run_finished_at",
            "description": "Parent run finish time, in RFC 3339 format. Empty until the run finishes."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow."
          },
          "workflowName": {
            "type": "string",
            "title": "workflow_name",
            "description": "Workflow name from the YAML `name:` key, falling back to the file path stem. Empty when neither is available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "workflowStatus": {
            "type": "string",
            "title": "workflow_status",
            "description": "Current state of the workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "workflowErrorMessage": {
            "type": "string",
            "title": "workflow_error_message",
            "description": "Workflow error or cancellation reason, for example a compilation or validation error. Empty when the workflow is healthy."
          },
          "workflowCreatedAt": {
            "type": "string",
            "title": "workflow_created_at",
            "description": "Workflow creation time, in RFC 3339 format."
          },
          "workflowStartedAt": {
            "type": "string",
            "title": "workflow_started_at",
            "description": "Workflow start time, in RFC 3339 format. Empty until the workflow starts."
          },
          "workflowFinishedAt": {
            "type": "string",
            "title": "workflow_finished_at",
            "description": "Workflow finish time, in RFC 3339 format. Empty until the workflow finishes."
          },
          "executions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.GetWorkflowExecution"
            },
            "title": "executions",
            "description": "Workflow-level execution records; each re-run creates another execution."
          },
          "jobs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.GetWorkflowJob"
            },
            "title": "jobs",
            "description": "Workflow jobs and their per-job attempts."
          }
        },
        "title": "GetWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.JobAttemptLogExportFormat": {
        "type": "string",
        "title": "JobAttemptLogExportFormat",
        "enum": [
          "JOB_ATTEMPT_LOG_EXPORT_FORMAT_UNSPECIFIED",
          "JOB_ATTEMPT_LOG_EXPORT_FORMAT_TEXT",
          "JOB_ATTEMPT_LOG_EXPORT_FORMAT_JSONL"
        ],
        "description": "Byte format used when exporting a job attempt's persisted logs."
      },
      "depot.ci.v1.JobAttemptLogExportMetadata": {
        "type": "object",
        "properties": {
          "filename": {
            "type": "string",
            "title": "filename",
            "description": "Advisory, non-stable basename hint for generated clients. Not a destination path; clients must not depend on the stem staying stable across calls. The filename is basename-only ASCII and ends in .txt for text or .jsonl for JSONL."
          },
          "contentType": {
            "type": "string",
            "title": "content_type",
            "description": "Exact media type for chunk bytes: `text/plain; charset=utf-8` for text or `application/x-ndjson; charset=utf-8` for JSONL."
          },
          "format": {
            "title": "format",
            "description": "Selected byte format for following chunk responses.",
            "$ref": "#/components/schemas/depot.ci.v1.JobAttemptLogExportFormat"
          }
        },
        "title": "JobAttemptLogExportMetadata",
        "additionalProperties": false
      },
      "depot.ci.v1.JobDetailAttempt": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1 for the first run."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the attempt, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the attempt concludes."
          },
          "errorMessage": {
            "type": "string",
            "title": "error_message",
            "description": "Attempt error message populated for orchestration or worker failures. Empty when the attempt has no error."
          },
          "sandboxId": {
            "type": "string",
            "title": "sandbox_id",
            "description": "Unique identifier for the sandbox that ran this attempt, when one exists."
          },
          "sessionId": {
            "type": "string",
            "title": "session_id",
            "description": "Unique identifier for the interactive session attached to that sandbox, when one is available."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Attempt creation time, in RFC 3339 format."
          },
          "dispatchedAt": {
            "type": "string",
            "title": "dispatched_at",
            "description": "Attempt dispatch time, in RFC 3339 format. Empty until the attempt is dispatched to a worker."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Attempt start time, in RFC 3339 format. Empty until the attempt starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Attempt finish time, in RFC 3339 format. Empty until the attempt finishes."
          },
          "isCurrent": {
            "type": "boolean",
            "title": "is_current",
            "description": "True when this attempt is the job's current attempt."
          }
        },
        "title": "JobDetailAttempt",
        "additionalProperties": false
      },
      "depot.ci.v1.JobDetailDependency": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the dependency job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Job key from the workflow, for example \"build\" or \"test\"."
          },
          "jobDisplayName": {
            "type": "string",
            "title": "job_display_name",
            "description": "Human-readable display name from the workflow, falling back to `jobKey` when no display name is set."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the dependency job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the dependency job, for example \"success\", \"failure\", \"cancelled\", \"skipped\", or \"timed_out\". Empty until the job concludes."
          },
          "errorMessage": {
            "type": "string",
            "title": "error_message",
            "description": "Dependency job error message populated for orchestration or worker failures. Empty when the job has no error."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Dependency job creation time, in RFC 3339 format."
          },
          "dispatchedAt": {
            "type": "string",
            "title": "dispatched_at",
            "description": "Dependency job dispatch time, in RFC 3339 format. Empty until the job is dispatched to a worker."
          },
          "startedAt": {
            "type": "string",
            "title": "started_at",
            "description": "Dependency job start time, in RFC 3339 format. Empty until the job starts."
          },
          "finishedAt": {
            "type": "string",
            "title": "finished_at",
            "description": "Dependency job finish time, in RFC 3339 format. Empty until the job finishes."
          }
        },
        "title": "JobDetailDependency",
        "additionalProperties": false
      },
      "depot.ci.v1.JobDetailMatrixValue": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string",
            "title": "key",
            "description": "Matrix dimension name, for example \"os\" or \"node-version\"."
          },
          "value": {
            "type": "string",
            "title": "value",
            "description": "Matrix dimension value for this job instance, serialized as a string."
          }
        },
        "title": "JobDetailMatrixValue",
        "additionalProperties": false
      },
      "depot.ci.v1.JobDetailRunsOn": {
        "type": "object",
        "properties": {
          "labels": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "labels",
            "description": "Runner labels declared on the job's `runs-on`."
          },
          "image": {
            "type": "string",
            "title": "image",
            "description": "Container image used for the job, when one is configured. Empty otherwise."
          },
          "cpus": {
            "type": "integer",
            "title": "cpus",
            "format": "int32",
            "description": "CPU count allocated to the runner. Zero when unset."
          },
          "memoryGb": {
            "type": "integer",
            "title": "memory_gb",
            "format": "int32",
            "description": "Memory allocated to the runner, in gigabytes. Zero when unset."
          },
          "size": {
            "type": "string",
            "title": "size",
            "description": "Resolved runner size string, for example \"small\" or \"large\". Empty when unset."
          }
        },
        "title": "JobDetailRunsOn",
        "additionalProperties": false
      },
      "depot.ci.v1.JobDetailStrategy": {
        "type": "object",
        "properties": {
          "jobIndex": {
            "type": "integer",
            "title": "job_index",
            "format": "int32",
            "description": "Zero-based index of this job within the matrix expansion."
          },
          "jobTotal": {
            "type": "integer",
            "title": "job_total",
            "format": "int32",
            "description": "Total number of jobs produced by the matrix expansion."
          }
        },
        "title": "JobDetailStrategy",
        "additionalProperties": false
      },
      "depot.ci.v1.JobStatus": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Job key from the workflow, for example \"build\" or \"test\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the job, for example \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", \"cancelled\", or \"skipped\". \"waiting\" means the job is blocked behind another run that holds the same `concurrency:` group slot."
          },
          "attempts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.AttemptStatus"
            },
            "title": "attempts",
            "description": "All attempts for this job, including the original and any retries. Each contains the attempt's identifier, number, current status, and sandbox/session IDs (when active). Order is not guaranteed."
          }
        },
        "title": "JobStatus",
        "additionalProperties": false
      },
      "depot.ci.v1.ListArtifactsRequest": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run. Returned by `Run`, `DispatchWorkflow`, and `ListRuns`."
          },
          "workflowId": {
            "type": [
              "string",
              "null"
            ],
            "title": "workflow_id",
            "description": "Optionally narrows the list to artifacts from one workflow in the run."
          },
          "jobId": {
            "type": [
              "string",
              "null"
            ],
            "title": "job_id",
            "description": "Optionally narrows the list to artifacts from one job in the run."
          },
          "attemptId": {
            "type": [
              "string",
              "null"
            ],
            "title": "attempt_id",
            "description": "Optionally narrows the list to artifacts from one job attempt in the run."
          },
          "pageSize": {
            "type": "integer",
            "title": "page_size",
            "format": "int32",
            "description": "Maximum number of artifacts to return. Capped at 500. Default: 100."
          },
          "pageToken": {
            "type": "string",
            "title": "page_token",
            "description": "Resumes cursor pagination from a previous response."
          }
        },
        "title": "ListArtifactsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.ListArtifactsResponse": {
        "type": "object",
        "properties": {
          "artifacts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.Artifact"
            },
            "title": "artifacts",
            "description": "Artifacts matching the request, up to page_size entries."
          },
          "nextPageToken": {
            "type": [
              "string",
              "null"
            ],
            "title": "next_page_token",
            "description": "Token to retrieve the next page of results. Unset when no more pages are available."
          }
        },
        "title": "ListArtifactsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.ListRunsRequest": {
        "type": "object",
        "properties": {
          "status": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "status",
            "description": "Statuses of runs to return, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\". Multiple values are ORed. Default: [\"running\", \"queued\"]."
          },
          "pageSize": {
            "type": "integer",
            "title": "page_size",
            "format": "int32",
            "description": "Number of runs to return per page. Maximum: 100. Default: 50."
          },
          "pageToken": {
            "type": "string",
            "title": "page_token",
            "description": "Token to fetch the next page of runs. Use the `nextPageToken` value from a prior response. Leave empty to fetch the first page."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "Repository to return runs from, in `owner/name` format, for example \"depot/cli\". Required if `pr` is set."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA prefix to return runs for. Matched against the run's `sha` or `headSha`. 1-40 hex characters."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Trigger event to return runs for, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "pr": {
            "type": "string",
            "title": "pr",
            "description": "Pull request number to return runs for. Requires `repo`."
          }
        },
        "title": "ListRunsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.ListRunsResponse": {
        "type": "object",
        "properties": {
          "runs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.ListRunsResponseRun"
            },
            "title": "runs",
            "description": "Recent runs matching the request, newest first."
          },
          "nextPageToken": {
            "type": "string",
            "title": "next_page_token",
            "description": "Token to retrieve the next page of results. Empty when no more pages are available."
          }
        },
        "title": "ListRunsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.ListRunsResponseRun": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the CI run."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the run executes against. Empty for open pull_request runs."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the run, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Run creation time, in RFC 3339 format."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Git ref the run was triggered against, for example \"refs/heads/main\" or \"refs/pull/42/merge\". Empty when the trigger carries no ref."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          }
        },
        "title": "ListRunsResponseRun",
        "additionalProperties": false
      },
      "depot.ci.v1.ListWorkflowsRequest": {
        "type": "object",
        "properties": {
          "pageSize": {
            "type": "integer",
            "title": "page_size",
            "format": "int32",
            "description": "Number of workflows to return per page. Maximum: 200. Default: 50."
          },
          "name": {
            "type": "string",
            "title": "name",
            "description": "Filters recent workflows by substring match on the workflow name or path fallback."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "Filters recent workflows by repo in {owner}/{repo} format."
          },
          "status": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "status",
            "description": "Filters recent workflows by workflow status. Multiple values are ORed."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Filters recent workflows by the parent run trigger, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Filters recent workflows by parent run head SHA prefix."
          },
          "pr": {
            "type": "string",
            "title": "pr",
            "description": "Filters recent workflows by pull request number."
          }
        },
        "title": "ListWorkflowsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.ListWorkflowsResponse": {
        "type": "object",
        "properties": {
          "workflows": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.ListWorkflowsResponseWorkflow"
            },
            "title": "workflows",
            "description": "Recent workflows matching the request, newest first."
          }
        },
        "title": "ListWorkflowsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.ListWorkflowsResponseJobCounts": {
        "type": "object",
        "properties": {
          "total": {
            "type": "integer",
            "title": "total",
            "format": "int32",
            "description": "Total number of jobs in the workflow."
          },
          "queued": {
            "type": "integer",
            "title": "queued",
            "format": "int32",
            "description": "Number of jobs currently queued."
          },
          "waiting": {
            "type": "integer",
            "title": "waiting",
            "format": "int32",
            "description": "Number of jobs waiting on dependencies."
          },
          "running": {
            "type": "integer",
            "title": "running",
            "format": "int32",
            "description": "Number of jobs currently running."
          },
          "finished": {
            "type": "integer",
            "title": "finished",
            "format": "int32",
            "description": "Number of jobs that finished successfully."
          },
          "failed": {
            "type": "integer",
            "title": "failed",
            "format": "int32",
            "description": "Number of jobs that failed."
          },
          "cancelled": {
            "type": "integer",
            "title": "cancelled",
            "format": "int32",
            "description": "Number of jobs that were cancelled."
          },
          "skipped": {
            "type": "integer",
            "title": "skipped",
            "format": "int32",
            "description": "Number of jobs that were skipped."
          }
        },
        "title": "ListWorkflowsResponseJobCounts",
        "additionalProperties": false
      },
      "depot.ci.v1.ListWorkflowsResponseWorkflow": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow."
          },
          "name": {
            "type": "string",
            "title": "name",
            "description": "Workflow name from the YAML `name:` key, falling back to the file path stem. Empty when neither is available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository in `owner/name` format, for example \"depot/cli\"."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Event that triggered the parent run, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA the parent run executes against. Empty for open pull_request runs."
          },
          "headSha": {
            "type": "string",
            "title": "head_sha",
            "description": "Source commit SHA for pull_request and merge_group triggers. Empty for triggers that don't carry a head SHA."
          },
          "createdAt": {
            "type": "string",
            "title": "created_at",
            "description": "Workflow creation time, in RFC 3339 format."
          },
          "jobCounts": {
            "title": "job_counts",
            "description": "Counts of jobs in the workflow broken down by status.",
            "$ref": "#/components/schemas/depot.ci.v1.ListWorkflowsResponseJobCounts"
          }
        },
        "title": "ListWorkflowsResponseWorkflow",
        "additionalProperties": false
      },
      "depot.ci.v1.LogLine": {
        "type": "object",
        "properties": {
          "stepKey": {
            "type": "string",
            "title": "step_key",
            "description": "Stable Depot log/step correlation key."
          },
          "timestampMs": {
            "type": [
              "integer",
              "string"
            ],
            "title": "timestamp_ms",
            "format": "int64",
            "description": "Log timestamp as Unix epoch milliseconds."
          },
          "lineNumber": {
            "type": "integer",
            "title": "line_number",
            "description": "Persisted line number within the emitting stream."
          },
          "stream": {
            "type": "integer",
            "title": "stream",
            "description": "0 for stdout, 1 for stderr."
          },
          "body": {
            "type": "string",
            "title": "body",
            "description": "Log line content without transport framing."
          },
          "stepId": {
            "type": "string",
            "title": "step_id",
            "description": "User-authored workflow step ID, when available."
          },
          "stepName": {
            "type": "string",
            "title": "step_name",
            "description": "User-authored workflow step name, when available."
          }
        },
        "title": "LogLine",
        "additionalProperties": false
      },
      "depot.ci.v1.RelevantErrorLine": {
        "type": "object",
        "properties": {
          "stepId": {
            "type": "string",
            "title": "step_id",
            "description": "Workflow step identifier the line was emitted from. Empty when not associated with a step."
          },
          "lineNumber": {
            "type": "integer",
            "title": "line_number",
            "description": "Persisted line number within the emitting stream."
          },
          "content": {
            "type": "string",
            "title": "content",
            "description": "Log line content, possibly truncated."
          },
          "contentTruncated": {
            "type": "boolean",
            "title": "content_truncated",
            "description": "True when content was truncated to fit the per-line limit."
          },
          "contentOriginalLength": {
            "type": "integer",
            "title": "content_original_length",
            "description": "Original length of content before truncation."
          }
        },
        "title": "RelevantErrorLine",
        "additionalProperties": false
      },
      "depot.ci.v1.RepresentativeAttempt": {
        "type": "object",
        "properties": {
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the parent CI run."
          },
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the parent workflow."
          },
          "workflowName": {
            "type": "string",
            "title": "workflow_name",
            "description": "Parent workflow name from the YAML `name:` key, falling back to the file path stem. Empty when not available."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Parent workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the parent job."
          },
          "jobKey": {
            "type": "string",
            "title": "job_key",
            "description": "Parent job key from the workflow."
          },
          "jobDisplayName": {
            "type": "string",
            "title": "job_display_name",
            "description": "Human-readable display name for the parent job, falling back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "title": "job_status",
            "description": "Current state of the parent job.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "jobConclusion": {
            "title": "job_conclusion",
            "description": "Conclusion of the parent job. Unspecified until the job concludes.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisConclusion"
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for this attempt."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number, starting at 1 for the first run."
          },
          "attemptStatus": {
            "title": "attempt_status",
            "description": "Current state of the attempt.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisResourceStatus"
          },
          "attemptConclusion": {
            "title": "attempt_conclusion",
            "description": "Conclusion of the attempt. Unspecified until the attempt concludes.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisConclusion"
          },
          "errorMessage": {
            "type": "string",
            "title": "error_message",
            "description": "Error message captured for this attempt, possibly truncated."
          },
          "errorMessageTruncated": {
            "type": "boolean",
            "title": "error_message_truncated",
            "description": "True when error_message was truncated to fit the response limit."
          },
          "errorMessageOriginalLength": {
            "type": "integer",
            "title": "error_message_original_length",
            "description": "Original length of error_message before truncation."
          },
          "diagnosis": {
            "type": "string",
            "title": "diagnosis",
            "description": "AI-generated diagnosis for this attempt. Empty when no diagnosis is available."
          },
          "possibleFix": {
            "type": "string",
            "title": "possible_fix",
            "description": "AI-generated suggested fix for this attempt. Empty when no suggestion is available."
          },
          "relevantLines": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.RelevantErrorLine"
            },
            "title": "relevant_lines",
            "description": "Selected log lines correlated with the failure."
          },
          "nextCommands": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.DrillDownCommand"
            },
            "title": "next_commands",
            "description": "Drill-down commands suggested for this attempt, for example \"depot ci logs\" or \"depot ci summary\"."
          }
        },
        "title": "RepresentativeAttempt",
        "additionalProperties": false
      },
      "depot.ci.v1.RerunWorkflowRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow to re-run."
          }
        },
        "title": "RerunWorkflowRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.RerunWorkflowResponse": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow. Matches the request workflow_id; a re-run creates a new workflow execution rather than a new workflow."
          },
          "jobCount": {
            "type": "integer",
            "title": "job_count",
            "format": "int32",
            "description": "Number of jobs reset to queued."
          }
        },
        "title": "RerunWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryFailedJobsRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing failed jobs."
          }
        },
        "title": "RetryFailedJobsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryFailedJobsResponse": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow. Matches the request workflow_id; a retry creates a new workflow execution rather than a new workflow."
          },
          "jobIds": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "job_ids",
            "description": "Unique identifiers for jobs that were set back to queued. A new attempt is created for each job when it runs again."
          },
          "jobCount": {
            "type": "integer",
            "title": "job_count",
            "format": "int32",
            "description": "Number of jobs reset to queued."
          }
        },
        "title": "RetryFailedJobsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryJobRequest": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing the job."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job to retry."
          }
        },
        "title": "RetryJobRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryJobResponse": {
        "type": "object",
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job. Matches the request job_id; a retry creates a new attempt rather than a new job."
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Empty in the response. The new attempt is created once the job runs again and is visible through GetJob.attempts."
          },
          "attempt": {
            "type": "integer",
            "title": "attempt",
            "format": "int32",
            "description": "Attempt number the next attempt will use, one greater than the prior attempt."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "New job status, typically \"queued\"."
          }
        },
        "title": "RetryJobResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RunRequest": {
        "type": "object",
        "properties": {
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository to run against, in `owner/name` format, for example \"depot/cli\". Must be connected to your Depot organization through the Depot GitHub app."
          },
          "sha": {
            "type": [
              "string",
              "null"
            ],
            "title": "sha",
            "description": "Commit SHA to run against. Use a specific commit to run a particular version of your workflow files (and have that SHA appear in github.sha), or omit to run the latest commit on the default branch. Must be a full 40-character hex SHA. Default: HEAD of the default branch."
          },
          "workflow": {
            "type": [
              "string",
              "null"
            ],
            "title": "workflow",
            "description": "Path of the workflow file to run, relative to the repo root, for example \".depot/workflows/ci.yml\". Mutually exclusive with `workflowContent`; if neither is provided, runs all workflows in the repo."
          },
          "workflowContent": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "workflow_content",
            "description": "An array of workflow YAMLs to run. Depot reads the YAML from the request instead of the repo. Each entry must be the complete content of a workflow (the same YAML you would commit to `.depot/workflows/`). Useful for testing workflow YAML changes without committing them. Mutually exclusive with `workflow`; if neither is provided, runs all workflows in the repo."
          },
          "job": {
            "type": [
              "string",
              "null"
            ],
            "title": "job",
            "description": "Run a single job from within a workflow. Other jobs in the workflow are skipped. Only valid when a single workflow is specified, either through `workflow` or a `workflowContent` entry containing one workflow."
          }
        },
        "title": "RunRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.RunResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Organization that owns this run."
          },
          "runId": {
            "type": "string",
            "title": "run_id",
            "description": "Unique identifier for the created CI run. Use it for methods like `GetRun`, `GetRunStatus`, `CancelRun`, and `ListArtifacts` to track, cancel, or fetch results from the run."
          }
        },
        "title": "RunResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.StreamJobAttemptLogsRequest": {
        "type": "object",
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt. Set exactly one of attempt_id or job_id."
          },
          "cursor": {
            "type": "string",
            "title": "cursor",
            "description": "Opaque cursor returned by a previous stream response for the same target. Omit it to stream from the first persisted line."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for a CI job. The stream resolves it to that job's latest attempt. Set exactly one of attempt_id or job_id."
          }
        },
        "title": "StreamJobAttemptLogsRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.StreamJobAttemptLogsResponse": {
        "type": "object",
        "properties": {
          "line": {
            "title": "line",
            "description": "Set when this response carries a persisted log line. Status-only responses can omit it while the stream is waiting for rows.",
            "$ref": "#/components/schemas/depot.ci.v1.LogLine"
          },
          "nextCursor": {
            "type": "string",
            "title": "next_cursor",
            "description": "Opaque cursor to resume after the emitted line."
          },
          "attemptStatus": {
            "type": "string",
            "title": "attempt_status",
            "description": "Current state of the attempt, for example \"running\", \"finished\", \"failed\", or \"cancelled\"."
          }
        },
        "title": "StreamJobAttemptLogsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.WorkflowStatus": {
        "type": "object",
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the workflow, for example \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "workflowPath": {
            "type": "string",
            "title": "workflow_path",
            "description": "Workflow file path, for example \".depot/workflows/ci.yml\". Empty when the workflow YAML was passed via `workflowContent` in the `Run` request."
          },
          "jobs": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobStatus"
            },
            "title": "jobs",
            "description": "Jobs that make up the workflow."
          },
          "name": {
            "type": "string",
            "title": "name",
            "description": "Workflow name from the YAML `name:` key. Empty when not set."
          },
          "errorMessage": {
            "type": "string",
            "title": "error_message",
            "description": "Workflow error or cancellation reason, for example a compilation or validation error. Empty when the workflow is healthy."
          }
        },
        "title": "WorkflowStatus",
        "additionalProperties": false
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "API token"
      }
    }
  },
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "CIService",
      "description": "CIService is the customer-facing API for managing CI runs, workflows, and jobs. Authenticated with organization or app tokens."
    }
  ]
}