builds

Create a build by repo + source slug

Creates a build by addressing the pipeline through its repo-natural identity (repo_name + source_slug) rather than the org-global slug. This is the hm run path. Resolution, manual-build gating, billing, and IR handling are otherwise identical to createBuild. A repo/source slug that matches no pipeline yields 404.

post/api/v0/organizations/{org}/builds

Request

  • Base URL: https://api.harmont.dev
  • URL: https://api.harmont.dev/api/v0/organizations/{org}/builds
  • Auth: HTTP bearer

Path parameters

orgstring required

The organization slug.

Request body

branchstring required

Source branch.

commitstring required

Source commit SHA.

envobject nullable

Build-level environment variables.

messagestring nullable

Optional build/commit message.

pipeline_irstring nullable

The pre-rendered v0 IR JSON the engine materialises into jobs. When absent/blank the engine renders the pipeline's IR in a sandbox VM instead.

repo_namestring required

The worktree's repository as owner/repo (from its git remote).

sourcestring nullable

How the build was triggered (e.g. api, ui). Defaults to api.

source_b64string nullable

Base64-encoded source tarball (the hm run local-code upload). When present, the API stores it at the build's key and derives the internal, runner-token-authenticated source_url.

source_slugstring required

The in-repo pipeline name — the @hm.pipeline("…") slug.

Response

The created build

branchstring nullable

Source branch.

commitstring nullable

Source commit SHA.

created_atstring date-time required

When the build row was created.

error_codestring nullable

Stable build-level error code, if the build failed at the build level.

error_messagestring nullable

Human-readable build-level error message, if any.

finished_atstring date-time nullable

When the build reached a terminal state.

messagestring nullable

Commit/build message.

numberinteger required

The build's number, sequential and unique within its pipeline.

pipeline_slugstring required

The global slug of the pipeline this build belongs to.

scheduled_atstring date-time nullable

When the build was queued.

sourcestring nullable

How the build was triggered (e.g. api, webhook, ui).

started_atstring date-time nullable

When the build started running.

state'scheduled' | 'running' | 'failing' | 'passed' | 'failed' | 'canceling' | 'canceled' required

The rolled-up build state.

Changes

No recorded changes to this operation across all 1 revision of this API.