> ## Documentation Index
> Fetch the complete documentation index at: https://docs.boat.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Get CI job

> One job's state, wait, run time, cost, sandbox and error.



## OpenAPI

````yaml openapi/boat-v1.yaml GET /ci/jobs/{jobId}
openapi: 3.1.0
info:
  title: Boat Public API v1
  version: 1.0.0
  description: >
    Public JSON API for creating, operating, prompting, observing, and exposing
    sandboxes from backend services, CI jobs, hosted workers, and Boat
    automation products.


    The v1 reference intentionally documents the developer integration surface
    only. Dashboard billing actions are not part of v1.
servers:
  - url: https://boat.dev/api/v1
security:
  - BoatBearerAuth: []
tags:
  - name: Boat
    description: >-
      Unified Boat account, setup, lifecycle, prompting, event history, desktop
      access, and SSH operations.
paths:
  /ci/jobs/{jobId}:
    get:
      tags:
        - Boat
      summary: Get CI job
      description: >-
        One job with its wait, run time, cost, sandbox and error. Needs an API
        key with `account.read`.
      operationId: getCiJob
      parameters:
        - name: jobId
          in: path
          required: true
          schema:
            type: string
          description: GitHub workflow job id.
      responses:
        '200':
          description: The job.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CiJobResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  schemas:
    CiJobResponse:
      allOf:
        - $ref: '#/components/schemas/SuccessBase'
        - type: object
          required:
            - job
          properties:
            type:
              type: string
              const: ci.job
            job:
              $ref: '#/components/schemas/CiJob'
    SuccessBase:
      type: object
      required:
        - ok
        - type
      properties:
        ok:
          type: boolean
          examples:
            - true
        type:
          type: string
          description: Stable success envelope discriminator added by v1.
    CiJob:
      type: object
      required:
        - id
        - repo
        - jobName
        - label
        - machineClass
        - state
        - queuedAt
      properties:
        id:
          type: string
          description: GitHub workflow job id.
          examples:
            - '122395651084'
        repo:
          type: string
          examples:
            - acme/api
        runId:
          type: string
        jobName:
          type: string
          examples:
            - test
        workflowName:
          type:
            - string
            - 'null'
          examples:
            - ci
        headBranch:
          type:
            - string
            - 'null'
          examples:
            - main
        headSha:
          type:
            - string
            - 'null'
        htmlUrl:
          type:
            - string
            - 'null'
          description: The job on GitHub.
        label:
          type: string
          description: The runs-on label that matched.
          examples:
            - boat-large/debug
        machineClass:
          type: string
          enum:
            - small
            - default
            - large
            - xlarge
        state:
          $ref: '#/components/schemas/CiJobState'
        error:
          type:
            - string
            - 'null'
          description: Why boat refused or could not start the job.
        sandboxId:
          type:
            - string
            - 'null'
          description: The sandbox this job's runner started.
        sandboxState:
          type:
            - string
            - 'null'
          enum:
            - live
            - busy
            - kept
            - deleted
            - null
          description: kept = a failed /debug job's sandbox, kept 30 minutes.
        queuedAt:
          type: string
          format: date-time
        runStartedAt:
          type:
            - string
            - 'null'
          format: date-time
        finishedAt:
          type:
            - string
            - 'null'
          format: date-time
        waitSeconds:
          type:
            - number
            - 'null'
          description: Queued on GitHub until a runner took it.
        runSeconds:
          type:
            - number
            - 'null'
        costDollars:
          type:
            - number
            - 'null'
          description: Sandbox time of the job at the size's rate.
    ErrorEnvelope:
      type: object
      required:
        - ok
        - type
        - status
        - code
        - message
        - error
        - requestId
      properties:
        ok:
          type: boolean
          examples:
            - false
        type:
          type: string
          examples:
            - sandbox.error
        status:
          type: integer
          examples:
            - 409
        code:
          type: string
          examples:
            - provider_not_configured
        message:
          type: string
          examples:
            - Prompting is locked until Codex is configured on the Agents page.
        requestId:
          type: string
          examples:
            - req_01HX...
        error:
          type: object
          required:
            - code
            - message
            - status
          properties:
            code:
              type: string
            message:
              type: string
            status:
              type: integer
            details:
              type: object
              additionalProperties: true
    CiJobState:
      type: string
      description: >-
        queued and running are active. failed = boat could not start a sandbox;
        refused = boat never runs it (unknown label, public repository).
      enum:
        - queued
        - running
        - success
        - failure
        - cancelled
        - skipped
        - failed
        - refused
  responses:
    Unauthorized:
      description: Missing or invalid bearer token.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
          examples:
            unauthorized:
              value:
                ok: false
                type: sandbox.error
                status: 401
                code: unauthorized
                message: Unauthorized
                error:
                  code: unauthorized
                  message: Unauthorized
                  status: 401
                requestId: req_01HX...
    NotFound:
      description: Resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
  securitySchemes:
    BoatBearerAuth:
      type: http
      scheme: bearer
      bearerFormat: sandbox_api_key
      description: >-
        Boat bearer token in the form `boat_...`. Service API keys authenticate
        sandbox operations.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.