OpenAI · Arazzo Workflow

OpenAI Download Batch Results

Version 1.0.0

Retrieve a completed batch and download its output file contents.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub Artificial IntelligenceLarge Language ModelsT1ArazzoWorkflows

Provider

openai

Workflows

download-batch-results
Download the output file of a completed batch.
Reads the batch to find its output file id, and only when the batch is completed does it download the raw output file contents.
2 steps inputs: apiKey, batchId outputs: contents, outputFileId
1
getBatch
Retrieve the batch and branch on whether it has completed.
2
downloadOutput
Download the contents of the batch output file.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: OpenAI Download Batch Results
  summary: Retrieve a completed batch and download its output file contents.
  description: >-
    Retrieves a batch, branches on its status, and when the batch has completed
    it downloads the contents of the output file that holds the results. 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: batchApi
  url: ../openapi/openai-batch-api-openapi.yml
  type: openapi
- name: filesApi
  url: ../openapi/openai-files-api-openapi.yml
  type: openapi
workflows:
- workflowId: download-batch-results
  summary: Download the output file of a completed batch.
  description: >-
    Reads the batch to find its output file id, and only when the batch is
    completed does it download the raw output file contents.
  inputs:
    type: object
    required:
    - apiKey
    - batchId
    properties:
      apiKey:
        type: string
        description: OpenAI API key used as a Bearer token.
      batchId:
        type: string
        description: The id of the batch whose results should be downloaded.
  steps:
  - stepId: getBatch
    description: Retrieve the batch and branch on whether it has completed.
    operationId: retrieveBatch
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.apiKey"
    - name: batch_id
      in: path
      value: $inputs.batchId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      status: $response.body#/status
      outputFileId: $response.body#/output_file_id
    onSuccess:
    - name: batchCompleted
      type: goto
      stepId: downloadOutput
      criteria:
      - context: $response.body
        condition: $.status == "completed"
        type: jsonpath
    - name: batchNotReady
      type: end
      criteria:
      - context: $response.body
        condition: $.status != "completed"
        type: jsonpath
  - stepId: downloadOutput
    description: Download the contents of the batch output file.
    operationId: downloadFile
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.apiKey"
    - name: file_id
      in: path
      value: $steps.getBatch.outputs.outputFileId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      contents: $response.body
  outputs:
    outputFileId: $steps.getBatch.outputs.outputFileId
    contents: $steps.downloadOutput.outputs.contents

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/openai-download-batch-results-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.