Buildkite · Arazzo Workflow

Buildkite Retry Failed Job

Version 1.0.0

Find a failed job in a build, retry it, then poll the build to completion.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub CI/CDContinuous IntegrationContinuous DeliveryDevOpsPipelinesHybrid CIBuild AutomationTest EnginePackage RegistriesAgentsGraphQLRESTMCPWebhookArazzoWorkflows

Provider

buildkite-com

Workflows

retry-failed-job
Retry a failed job and poll the build to completion.
Reads a build, retries the supplied failed job, and polls the build until it reaches a terminal state.
3 steps inputs: job, number, org, pipeline outputs: finalState, retriedJobId, webUrl
1
getBuild
Read the build to confirm it is terminal and capture its jobs before retrying.
2
retryJob
Retry the supplied failed job, which re-queues it for an available agent.
3
pollBuild
Poll the build until the retried job completes and the build leaves the running and scheduled states.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Buildkite Retry Failed Job
  summary: Find a failed job in a build, retry it, then poll the build to completion.
  description: >-
    A self-healing flow for flaky steps. The workflow reads a finished build,
    scans its jobs for a failed script job, retries that job, and then polls the
    build until it leaves the running state so the retry outcome can be observed.
    This lets automation recover from transient failures without re-running the
    entire build. Every step spells out its request inline so the flow can be
    read and executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: buildsApi
  url: ../openapi/buildkite-com-builds-api-openapi.yml
  type: openapi
- name: jobsApi
  url: ../openapi/buildkite-com-jobs-api-openapi.yml
  type: openapi
workflows:
- workflowId: retry-failed-job
  summary: Retry a failed job and poll the build to completion.
  description: >-
    Reads a build, retries the supplied failed job, and polls the build until it
    reaches a terminal state.
  inputs:
    type: object
    required:
    - org
    - pipeline
    - number
    - job
    properties:
      org:
        type: string
        description: Organization slug that owns the pipeline.
      pipeline:
        type: string
        description: Pipeline slug the build belongs to.
      number:
        type: integer
        description: Build number containing the job to retry.
      job:
        type: string
        description: UUID of the failed job to retry.
  steps:
  - stepId: getBuild
    description: >-
      Read the build to confirm it is terminal and capture its jobs before
      retrying.
    operationId: getBuild
    parameters:
    - name: org
      in: path
      value: $inputs.org
    - name: pipeline
      in: path
      value: $inputs.pipeline
    - name: number
      in: path
      value: $inputs.number
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      buildState: $response.body#/state
      jobs: $response.body#/jobs
  - stepId: retryJob
    description: >-
      Retry the supplied failed job, which re-queues it for an available agent.
    operationId: retryJob
    parameters:
    - name: org
      in: path
      value: $inputs.org
    - name: pipeline
      in: path
      value: $inputs.pipeline
    - name: number
      in: path
      value: $inputs.number
    - name: job
      in: path
      value: $inputs.job
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      jobId: $response.body#/id
      jobState: $response.body#/state
  - stepId: pollBuild
    description: >-
      Poll the build until the retried job completes and the build leaves the
      running and scheduled states.
    operationId: getBuild
    parameters:
    - name: org
      in: path
      value: $inputs.org
    - name: pipeline
      in: path
      value: $inputs.pipeline
    - name: number
      in: path
      value: $inputs.number
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      finalState: $response.body#/state
      webUrl: $response.body#/web_url
    onSuccess:
    - name: stillRunning
      type: goto
      stepId: pollBuild
      criteria:
      - context: $response.body
        condition: $.state == "running" || $.state == "scheduled"
        type: jsonpath
  outputs:
    retriedJobId: $steps.retryJob.outputs.jobId
    finalState: $steps.pollBuild.outputs.finalState
    webUrl: $steps.pollBuild.outputs.webUrl

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/buildkite-com-retry-failed-job-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.