{
  "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, waiting, or running job and its active attempt.",
        "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 configured with an `on.workflow_dispatch` trigger and validates inputs against its input 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": "The response is a Connect/gRPC server stream, not a raw HTTP file download. Consume it with a generated client or a decoder that understands stream framing. 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 short-lived signed HTTPS URL for one artifact. The URL expires 5 minutes after issuance.",
        "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 an attempt's identity, status, timestamps, and sandbox/session IDs, with parent run, workflow, and job 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": "Returns a failure diagnosis for a run, workflow, job, or attempt.",
        "description": "For run and workflow targets, identical failures are grouped together by error fingerprint. For job and attempt targets, the response is a focused diagnosis of that single job or attempt. When too many jobs failed to diagnose individually, the response is a per-workflow and per-job breakdown instead. When no failure evidence is found, the response is empty. The response is limited to a fixed size and reflects the run's current state. The diagnosis can change while a run is in progress. As more jobs fail, a later call can surface new failures or turn an empty result into a grouped one. As job summaries become available, a later call can also add summary drill-down commands.",
        "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 a job's identity, status, timestamps, runner configuration, parent run and workflow context, dependencies, 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 persisted log lines for a job attempt, oldest first. Identify the attempt by `attemptId`, or by `jobId` to use the job's latest attempt. Poll with `pageToken` to fetch lines persisted after a previous response.",
        "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 a workflow's identity, status, timestamps, parent run context, execution history, and nested jobs and attempts.",
        "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, optionally narrowed to a workflow, job, or attempt. Download URLs are not included; request one per artifact with `GetArtifactDownloadURL`.",
        "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. Use `pageSize` 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 every job in a workflow that's in a terminal state (finished, failed, or cancelled) to queued and runs them all again. Cancel the workflow first if it's still running.",
        "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 the failed and cancelled jobs in a workflow, along with any skipped jobs that depend on them. Jobs that already succeeded are left untouched.",
        "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 or cancelled job, along with any skipped jobs that depend on it. Fails when a job that depends on it has already started; use `RetryFailedJobs` to retry related failures together.",
        "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 a job attempt's persisted log lines, streaming new lines while the attempt runs.",
        "description": "The response is a Connect/gRPC server stream, not raw text. Consume it with a generated client or a decoder that understands stream framing. Every response reports the attempt's current status. Responses that carry a log line also include `nextCursor`.\n\n To resume a dropped stream, save the newest `nextCursor` and send it as `cursor` on a new request. The new stream picks up after the last line you received. The stream ends on its own once the attempt has finished, failed, or been cancelled and all persisted lines have been sent.",
        "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. Pass it to `GetArtifactDownloadURL` to download the artifact."
          },
          "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. Can be \"queued\", \"waiting\", \"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. Can be \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the attempt. Can be \"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 maxReturnedSampleCount."
          },
          "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. Can be \"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. Can be \"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. Falls back to the file path stem when the workflow doesn't set `name:`. Empty when neither is 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",
        "required": [
          "workflowId",
          "jobId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing the job. Returned by `GetRunStatus` and `ListWorkflows`."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job to cancel. Returned by `GetRunStatus` and `GetWorkflow`."
          }
        },
        "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 `jobId`."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Updated job status. Should be \"cancelled\"."
          }
        },
        "title": "CancelJobResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelRunRequest": {
        "type": "object",
        "required": [
          "runId"
        ],
        "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": "Updated run status. Should be \"cancelled\"."
          }
        },
        "title": "CancelRunResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.CancelWorkflowRequest": {
        "type": "object",
        "required": [
          "workflowId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow to cancel. Returned by `GetRunStatus` and `ListWorkflows`."
          }
        },
        "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 `workflowId`."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Updated workflow status. Should be \"cancelled\"."
          }
        },
        "title": "CancelWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.DispatchWorkflowRequest": {
        "type": "object",
        "required": [
          "repo",
          "workflow"
        ],
        "properties": {
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository to run workflows from, 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": "Path of the workflow file to run, relative to the repo root. For example, \".depot/workflows/deploy.yml\". The workflow must be configured with an `on.workflow_dispatch` trigger. Required."
          },
          "ref": {
            "type": "string",
            "title": "ref",
            "description": "Branch or tag to run the workflow on. An unqualified name like \"main\" is treated as a branch. To use a tag, pass the fully-qualified ref \"refs/tags/v1.0\". Leave empty to use the repository's default branch. Default: HEAD of the default branch."
          },
          "inputs": {
            "type": "object",
            "title": "inputs",
            "additionalProperties": {
              "type": "string",
              "title": "value"
            },
            "description": "Inputs to pass to the workflow, as key-value pairs. All values are strings. The server validates each value against the workflow's `workflow_dispatch` input schema. Boolean inputs must be the string \"true\" or \"false\", number inputs must be numeric, and choice inputs must match one of the defined options. Unknown inputs are rejected. A required input must be supplied only if it has no default; one that has a default may be omitted."
          }
        },
        "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": "Depot 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": "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 `attemptId` or `jobId`."
          },
          "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 `attemptId` or `jobId`."
          },
          "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, at most 256 KiB per chunk. 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, the failed and cancelled jobs the diagnosis examined."
          },
          "failedProblemCandidateCap": {
            "type": "integer",
            "title": "failed_problem_candidate_cap",
            "description": "Maximum number of failed problem candidates the diagnosis examines. Above this limit the response switches to the over-limit breakdown."
          },
          "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 errorMessage 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 workflowName."
          },
          "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 `targetId`: 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. Falls back to the file path stem when the workflow doesn't set `name:`. 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, 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. Falls 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: Blocked behind another run that holds the same `concurrency:` group slot. 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."
      },
      "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 found. `failureGroups` and `representativeAttempts` are empty.\n - GROUPED_FAILURES: Failures grouped by fingerprint into `failureGroups`. 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. `overLimitBreakdown` 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 `targetId`: 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": "Identifier for this failure group, computed from the error text. Two failures share a fingerprint when their errors match after variable details like timestamps, IDs, and file paths are removed, so the same logical error from different attempts falls into the same group."
          },
          "source": {
            "type": "string",
            "title": "source",
            "description": "Origin of the error text used to form the fingerprint. Can be \"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 `errorMessage` was truncated to fit the response limit."
          },
          "errorMessageOriginalLength": {
            "type": "integer",
            "title": "error_message_original_length",
            "description": "Length of the full `errorMessage`, in characters, before any 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": "Attempts chosen as samples of the group's failure, up to `bounds.representativesPerGroupLimit` entries. Each job's current attempt is preferred, then more recent attempts."
          },
          "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",
        "required": [
          "artifactId"
        ],
        "properties": {
          "artifactId": {
            "type": "string",
            "title": "artifact_id",
            "description": "Unique identifier for the artifact. Returned by `ListArtifacts`."
          }
        },
        "title": "GetArtifactDownloadURLRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetArtifactDownloadURLResponse": {
        "type": "object",
        "properties": {
          "artifact": {
            "title": "artifact",
            "description": "Artifact metadata for the requested `artifactId`.",
            "$ref": "#/components/schemas/depot.ci.v1.Artifact"
          },
          "url": {
            "type": "string",
            "title": "url",
            "description": "Signed HTTPS URL for the artifact content. Works with any standard HTTPS client and needs no extra authentication; anyone holding the URL can download the artifact until it expires."
          },
          "expiresAt": {
            "type": "string",
            "title": "expires_at",
            "description": "Signed URL expiration time, in RFC 3339 format. URLs expire 5 minutes after issuance. Artifact retention is unaffected."
          }
        },
        "title": "GetArtifactDownloadURLResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetAttemptRequest": {
        "type": "object",
        "required": [
          "attemptId"
        ],
        "properties": {
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for the job attempt. Returned by `GetRunStatus`, `GetWorkflow`, and `GetJob`."
          }
        },
        "title": "GetAttemptRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetAttemptResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Depot 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. Can be \"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. Falls back to the file path stem when the workflow doesn't set `name:`. 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. Can be \"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. Falls back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "type": "string",
            "title": "job_status",
            "description": "Current state of the parent job. Can be \"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. Can be \"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.attemptId` 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": "Runner configuration from the parent job's `runs-on`: labels, image, CPU, memory, and size. Unset when no runner configuration is available.",
            "$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",
        "required": [
          "targetId",
          "targetType"
        ],
        "properties": {
          "targetId": {
            "type": "string",
            "title": "target_id",
            "description": "Unique identifier for the resource to diagnose: a CI run, workflow, job, or attempt. Must match `targetType`."
          },
          "targetType": {
            "title": "target_type",
            "description": "Resource type for `targetId`: 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": "Depot 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 found. `failureGroups` and `representativeAttempts` are empty.\n - GROUPED_FAILURES: Failures grouped by fingerprint into `failureGroups`. 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. `overLimitBreakdown` 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. Set only when `state` is EMPTY.",
            "$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": "Representative attempts from all failure groups in one list. Contains the same entries as the nested `failureGroups[].representatives` lists. Empty when `state` is EMPTY or OVER_LIMIT."
          },
          "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": "Drill-down commands from all representative attempts in one list. For example, \"depot ci logs\" or \"depot ci diagnose\". Contains the same entries as the nested `representativeAttempts[].nextCommands` lists. In an OVER_LIMIT response, contains the diagnose commands from `overLimitBreakdown[].nextCommands` instead. Empty when `state` is EMPTY."
          },
          "commandCapabilities": {
            "title": "command_capabilities",
            "description": "Availability flags for the suggested drill-down commands. Clients should hide commands whose flag is false. Unset means all commands are available.",
            "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisCommandCapabilities"
          },
          "overLimitBreakdown": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.FailureDiagnosisBreakdownRow"
            },
            "title": "over_limit_breakdown",
            "description": "Failure counts by workflow and by job, returned when failed problem candidates exceed `bounds.failedProblemCandidateCap`. 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. Set exactly one of `attemptId` or `jobId`."
          },
          "pageToken": {
            "type": "string",
            "title": "page_token",
            "description": "Token to fetch lines after a previous response. Use the `nextPageToken` value from a prior response. Leave empty to fetch from the first line."
          },
          "jobId": {
            "type": [
              "string",
              "null"
            ],
            "title": "job_id",
            "description": "Unique identifier for a CI job. Resolves to the job's latest attempt; the page token pins that attempt, so later pages stay on the same attempt even if a retry creates a newer one. Set exactly one of `attemptId` or `jobId`."
          }
        },
        "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, ordered by timestamp and line number."
          },
          "nextPageToken": {
            "type": "string",
            "title": "next_page_token",
            "description": "Token to fetch lines persisted after this response. Empty when the response contains no lines. While the attempt is running, poll with the newest token to tail new lines."
          }
        },
        "title": "GetJobAttemptLogsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobAttemptMetricsRequest": {
        "type": "object",
        "required": [
          "attemptId"
        ],
        "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",
        "required": [
          "jobId"
        ],
        "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",
        "required": [
          "jobId"
        ],
        "properties": {
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job. Returned by `GetRunStatus` and `GetWorkflow`."
          }
        },
        "title": "GetJobRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetJobResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Depot 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. Can be \"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. Falls back to the file path stem when the workflow doesn't set `name:`. 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. Can be \"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. Falls back to `jobKey` when no display name is set."
          },
          "jobStatus": {
            "type": "string",
            "title": "job_status",
            "description": "Current state of the job. Can be \"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. Can be \"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, and cleared while a retried job waits for its next attempt to be 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": "Runner configuration from the job's `runs-on`, such as labels, image, CPU, memory, and size. Unset when no runner configuration is available.",
            "$ref": "#/components/schemas/depot.ci.v1.JobDetailRunsOn"
          },
          "dependencies": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/depot.ci.v1.JobDetailDependency"
            },
            "title": "dependencies",
            "description": "Jobs this job depends on. Contains every dependency when the job has 100 or fewer; for jobs with more, a preview of 100 entries that prioritizes failed and cancelled dependencies."
          },
          "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 number of dependencies. Set only when `dependencies` is a capped preview."
          },
          "dependencyPreviewLimit": {
            "type": [
              "integer",
              "null"
            ],
            "title": "dependency_preview_limit",
            "format": "int32",
            "description": "Maximum number of entries returned in `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 attemptId is set."
          },
          "attemptId": {
            "type": "string",
            "title": "attempt_id",
            "description": "Unique identifier for a specific job attempt to summarize. Required unless jobId is set. When sent alongside jobId, 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. Can be \"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. Can be \"queued\", \"waiting\", \"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 hasSummary 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",
        "required": [
          "runId"
        ],
        "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",
        "required": [
          "runId"
        ],
        "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": "Depot 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. Can be \"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",
        "required": [
          "runId"
        ],
        "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": "Depot 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. Can be \"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. Can be \"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. Can be \"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. Can be \"queued\", \"waiting\", \"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",
        "required": [
          "workflowId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow. Returned by `GetRunStatus` and `ListWorkflows`."
          }
        },
        "title": "GetWorkflowRequest",
        "additionalProperties": false
      },
      "depot.ci.v1.GetWorkflowResponse": {
        "type": "object",
        "properties": {
          "orgId": {
            "type": "string",
            "title": "org_id",
            "description": "Depot 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. Can be \"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. Falls back to the file path stem when the workflow doesn't set `name:`. 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. Can be \"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": "Suggested filename for saving the export, with the extension matching the format. .txt for text or .jsonl for JSONL. The naming pattern isn't guaranteed and may change, so don't extract the attempt ID or other values from it."
          },
          "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. Can be \"queued\", \"waiting\", \"running\", \"finished\", \"failed\", or \"cancelled\"."
          },
          "conclusion": {
            "type": "string",
            "title": "conclusion",
            "description": "Conclusion of the attempt. Can be \"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. Falls back to `jobKey` when no display name is set."
          },
          "status": {
            "type": "string",
            "title": "status",
            "description": "Current state of the dependency job. Can be \"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. Can be \"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 specified 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": "Runner size from the job's `runs-on`, exactly as written in the workflow.\n\n Set whenever the runner config used a `${{ }}` expression in its size or image. The value is usually an expression like \"${{ vars.RUNNER_SIZE }}\", but can be a literal like \"4x16\" when only the image was the expression. In that case `cpus` and `memoryGb` are zero and stay zero for the life of the job, so this is the only runner-size value the API reports for it. Empty when the size was a plain literal with no expressions, in which case `cpus` and `memoryGb` carry the resolved values instead."
          }
        },
        "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. Can be \"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",
        "required": [
          "runId"
        ],
        "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": "Narrows the list to artifacts from one workflow. Must belong to the run. Leave unset to include all workflows."
          },
          "jobId": {
            "type": [
              "string",
              "null"
            ],
            "title": "job_id",
            "description": "Narrows the list to artifacts from one job. Must belong to the run, and to `workflowId` when both are set. Leave unset to include all jobs."
          },
          "attemptId": {
            "type": [
              "string",
              "null"
            ],
            "title": "attempt_id",
            "description": "Narrows the list to artifacts from one job attempt. Must belong to the run, and to `workflowId` and `jobId` when set. Leave unset to include all attempts."
          },
          "pageSize": {
            "type": "integer",
            "title": "page_size",
            "format": "int32",
            "description": "Number of artifacts to return per page. Maximum: 500. Default: 100."
          },
          "pageToken": {
            "type": "string",
            "title": "page_token",
            "description": "Token to fetch the next page of artifacts. Use the `nextPageToken` value from a prior response with the same filters. Leave empty to fetch the first page."
          }
        },
        "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 `pageSize` 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. Can be \"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. Can be \"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": "Text to match against the workflow name or file path. Only workflows containing this text are returned."
          },
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "Repository to return workflows from, in `owner/name` format. For example, \"depot/cli\"."
          },
          "status": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "title": "status",
            "description": "Statuses of workflows to return. Can be \"queued\", \"running\", \"finished\", \"failed\", or \"cancelled\". Multiple values are ORed."
          },
          "trigger": {
            "type": "string",
            "title": "trigger",
            "description": "Trigger event to return workflows for, for example \"push\", \"pull_request\", \"pull_request_target\", \"merge_group\", \"schedule\", \"workflow_run\", or \"workflow_dispatch\"."
          },
          "sha": {
            "type": "string",
            "title": "sha",
            "description": "Commit SHA prefix to return workflows for, matched against the parent run's `headSha`. 1-40 hex characters."
          },
          "pr": {
            "type": "string",
            "title": "pr",
            "description": "Pull request number to return workflows for."
          }
        },
        "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. Falls back to the file path stem when the workflow doesn't set `name:`. 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. Can be \"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": "Depot-assigned key correlating the line with a workflow step. Stable across responses for the same step."
          },
          "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 a trailing newline."
          },
          "stepId": {
            "type": "string",
            "title": "step_id",
            "description": "User-authored workflow step ID from the step's `id:` key. Empty when not set."
          },
          "stepName": {
            "type": "string",
            "title": "step_name",
            "description": "User-authored workflow step name from the step's `name:` key. Empty when not set."
          }
        },
        "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": "Length of the full `content`, in characters, before any 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. Falls back to the file path stem when the workflow doesn't set `name:`. 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."
          },
          "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. Falls 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 `errorMessage` was truncated to fit the response limit."
          },
          "errorMessageOriginalLength": {
            "type": "integer",
            "title": "error_message_original_length",
            "description": "Length of the full `errorMessage`, in characters, before any 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": "AI-selected log lines correlated with the failure. Empty when no log analysis is available."
          },
          "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,
        "description": "One attempt chosen as a sample of a failure group's error, with its error details, AI analysis, relevant log lines, and suggested drill-down commands."
      },
      "depot.ci.v1.RerunWorkflowRequest": {
        "type": "object",
        "required": [
          "workflowId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow to re-run. Returned by `GetRunStatus` and `ListWorkflows`."
          }
        },
        "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 `workflowId`. 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. A re-run resets every job in the workflow, so this is the workflow's total job count."
          }
        },
        "title": "RerunWorkflowResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryFailedJobsRequest": {
        "type": "object",
        "required": [
          "workflowId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing failed jobs. Returned by `GetRunStatus` and `ListWorkflows`."
          }
        },
        "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 `workflowId`. 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. Includes failed and cancelled jobs, plus any skipped jobs that depend on them. Equal to the number of entries in the `jobIds` array."
          }
        },
        "title": "RetryFailedJobsResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RetryJobRequest": {
        "type": "object",
        "required": [
          "workflowId",
          "jobId"
        ],
        "properties": {
          "workflowId": {
            "type": "string",
            "title": "workflow_id",
            "description": "Unique identifier for the workflow containing the job. Returned by `GetRunStatus` and `ListWorkflows`."
          },
          "jobId": {
            "type": "string",
            "title": "job_id",
            "description": "Unique identifier for the job to retry. Returned by `GetRunStatus` and `GetWorkflow`."
          }
        },
        "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 `jobId`. 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 appears in the `attempts` array returned by `GetJob`."
          },
          "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": "Updated job status. Should be \"queued\"."
          }
        },
        "title": "RetryJobResponse",
        "additionalProperties": false
      },
      "depot.ci.v1.RunRequest": {
        "type": "object",
        "required": [
          "repo"
        ],
        "properties": {
          "repo": {
            "type": "string",
            "title": "repo",
            "description": "GitHub repository to run workflows from, 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 (as found in `.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": "Job key of a single job to run from within a workflow. For example, \"build\" or \"test\". When specified, the run skips all other jobs in the workflow. Valid only 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": "Depot 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 `attemptId` or `jobId`."
          },
          "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 `attemptId` or `jobId`."
          }
        },
        "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. Set on responses that carry a line. Persist the newest value and send it as `cursor` on a later request."
          },
          "attemptStatus": {
            "type": "string",
            "title": "attempt_status",
            "description": "Current state of the attempt. Can be \"queued\", \"waiting\", \"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. Can be \"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."
    }
  ]
}