Skip to main content
Prisma Documentation Docs

Search documentation

Type to search this documentation.

List builds

GET/v1/buildsList builds

⚠️ Experimental endpoint: this API is in active development and may change at any time without notice. ⚠️

Lists the builds of the caller's workspace, newest first, filtered by project, branch, or state. cursor is opaque: pass back the nextCursor the previous page returned.

Parameters

cursornull | stringquery

Cursor for pagination

limitnumberquery

Limit for pagination

default 100

projectIdstringquery

pattern ^(proj_)?([cC][^\s-]{8,}|[a-z0-9]+)$

branchIdstringquery

pattern ^(br_)?([cC][^\s-]{8,}|[a-z0-9]+)$

statestringquery

one of "pending", "running", "succeeded", "failed", "cancelled"

one of "pending", "running", "succeeded", "failed", "cancelled"

Responses

200Builds, newest first.application/json
object
dataarray of objectrequired
Show child attributes
Show array items
applicationTopologyContentHashnull | stringrequired
branchIdnull | stringrequired

pattern ^(br_)([cC][^\s-]{8,}|[a-z0-9]+)$

branchNamestringrequired
commitShastringrequired
createdAtstringrequired
deployedUrlnull | stringrequired
errorMessagenull | stringrequired
externalLogUrlnull | stringrequired
failingStepnull | stringrequired
finishedAtnull | stringrequired
gitRepoIdnull | stringrequired

Repository the build ran against. Set only when the workspace has a live link to it; a reported repository the platform does not know stays null.

idstringrequired

pattern ^(bld_)([cC][^\s-]{8,}|[a-z0-9]+)$

phasenull | stringrequired

Null when nothing reported a phase; the platform never invents an observation it did not receive.

one of "queued", "build", "deploy", null

projectIdnull | stringrequired

pattern ^(proj_)([cC][^\s-]{8,}|[a-z0-9]+)$

sourcestringrequired

one of "webhook", "setup", "manual", "ci", "cli"

startedAtnull | stringrequired
statestringrequired

one of "pending", "running", "succeeded", "failed", "cancelled"

paginationobjectrequired
Show child attributes
hasMorebooleanrequired

Whether there are more items to paginate

nextCursornull | stringrequired

Next cursor to continue pagination

Example response
{
  "data": [
    {
      "applicationTopologyContentHash": "string",
      "branchId": "string",
      "branchName": "string",
      "commitSha": "string",
      "createdAt": "string",
      "deployedUrl": "string",
      "errorMessage": "string",
      "externalLogUrl": "string",
      "failingStep": "string",
      "finishedAt": "string",
      "gitRepoId": "string",
      "id": "string",
      "phase": "build",
      "projectId": "string",
      "source": "ci",
      "startedAt": "string",
      "state": "cancelled"
    }
  ],
  "pagination": {
    "hasMore": true,
    "nextCursor": "string"
  }
}
401Missing or invalid authorization token.application/json
object
errorobjectrequired
Show child attributes
codestringrequired
hintstring
messagestringrequired
Example response
{
  "error": {
    "code": "string",
    "hint": "string",
    "message": "string"
  }
}
404Build not found, or the caller's workspace does not own it (indistinguishable).application/json
object
errorobjectrequired
Show child attributes
codestringrequired
hintstring
messagestringrequired
Example response
{
  "error": {
    "code": "string",
    "hint": "string",
    "message": "string"
  }
}
429Rate limit exceeded.application/json
object
errorobjectrequired
Show child attributes
codestringrequired
hintstring
messagestringrequired
Example response
{
  "error": {
    "code": "string",
    "hint": "string",
    "message": "string"
  }
}
Documentation menu