# Build

> The Build object in the Guv API.

## Fields

| Field | Type | Description |
| --- | --- | --- |
| `id` * | string |  |
| `project_id` * | string |  |
| `environment_id` | string |  |
| `service_id` * | string |  |
| `deployment_id` | string or null |  |
| `status` * | `queued`, `running`, `succeeded`, `failed`, `cancelled`, `blocked` |  |
| `builder` * | `railpack`, `dockerfile`, `image` |  |
| `detected` | object or null |  |
| `commit` | [GitCommit](/docs/api/objects/git-commit/) or any or null |  |
| `image` | object or null |  |
| `scan` | object or null |  |
| `cache_hit_ratio` | number or null |  |
| `created_at` * | string (date-time) |  |
| `started_at` | string (date-time) or null |  |
| `finished_at` | string (date-time) or null |  |
| `duration_ms` | integer or null |  |

\* always present

## Example

```json
{
  "id": "bld_01jbx2m9k7q4r8t5v6w3y0z1pr",
  "project_id": "string",
  "environment_id": "string",
  "service_id": "string",
  "deployment_id": "string",
  "status": "queued",
  "builder": "railpack",
  "detected": {
    "language": "node",
    "language_version": "22",
    "framework": "nextjs",
    "summary": "We'll build a Next.js app with Node 22."
  },
  "commit": {
    "sha": "a1b2c3d4e5f60718293a4b5c6d7e8f9012345678",
    "branch": "string",
    "message": "string",
    "author": "string",
    "url": "https://guv.dev/"
  },
  "image": {
    "digest": "string",
    "size_bytes": 1,
    "signed": false,
    "sbom_url": "string",
    "provenance_url": "string"
  },
  "scan": {
    "secrets_found": 1,
    "secrets_in_bundle": 1,
    "vulnerabilities": {
      "critical": 1,
      "high": 1,
      "medium": 1,
      "low": 1,
      "kev": 1
    },
    "blocked": false,
    "block_reason": "string"
  },
  "cache_hit_ratio": 0.5,
  "created_at": "2026-10-22T13:05:00Z",
  "started_at": "2026-10-22T13:05:00Z",
  "finished_at": "2026-10-22T13:05:00Z",
  "duration_ms": 1
}
```

## Used by

- [Get a build](/docs/api/builds/#get-a-build)
- [Cancel a running build](/docs/api/builds/#cancel-a-running-build)
