OpenAI · Arazzo Workflow

OpenAI Retrieve and Delete Fine-Tuned Model

Version 1.0.0

Inspect a model and delete it only when it is an owned fine-tuned model.

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

Provider

openai

Workflows

retrieve-and-delete-model
Retrieve a model and delete it only when it is an owned fine-tuned model.
Reads a model's metadata and issues a delete only when the model is not an OpenAI-owned base model, protecting shared models from accidental deletion.
2 steps inputs: apiKey, model outputs: deleted, ownedBy
1
retrieveModel
Retrieve the model and branch on whether it is account-owned.
2
deleteModel
Delete the account-owned fine-tuned model.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: OpenAI Retrieve and Delete Fine-Tuned Model
  summary: Inspect a model and delete it only when it is an owned fine-tuned model.
  description: >-
    Retrieves a model to inspect who owns it, then branches: when the model is
    owned by the account (a fine-tuned model whose owner is not openai) it
    deletes the model, otherwise the flow ends without deleting a shared base
    model. 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: modelsApi
  url: ../openapi/openai-models-api-openapi.yml
  type: openapi
workflows:
- workflowId: retrieve-and-delete-model
  summary: Retrieve a model and delete it only when it is an owned fine-tuned model.
  description: >-
    Reads a model's metadata and issues a delete only when the model is not an
    OpenAI-owned base model, protecting shared models from accidental deletion.
  inputs:
    type: object
    required:
    - apiKey
    - model
    properties:
      apiKey:
        type: string
        description: OpenAI API key used as a Bearer token.
      model:
        type: string
        description: The id of the model to inspect and possibly delete.
  steps:
  - stepId: retrieveModel
    description: Retrieve the model and branch on whether it is account-owned.
    operationId: retrieveModel
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.apiKey"
    - name: model
      in: path
      value: $inputs.model
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      ownedBy: $response.body#/owned_by
    onSuccess:
    - name: ownedModel
      type: goto
      stepId: deleteModel
      criteria:
      - context: $response.body
        condition: $.owned_by != "openai"
        type: jsonpath
    - name: baseModel
      type: end
      criteria:
      - context: $response.body
        condition: $.owned_by == "openai"
        type: jsonpath
  - stepId: deleteModel
    description: Delete the account-owned fine-tuned model.
    operationId: deleteModel
    parameters:
    - name: Authorization
      in: header
      value: "Bearer $inputs.apiKey"
    - name: model
      in: path
      value: $inputs.model
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      deleted: $response.body#/deleted
  outputs:
    ownedBy: $steps.retrieveModel.outputs.ownedBy
    deleted: $steps.deleteModel.outputs.deleted

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-retrieve-and-delete-model-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.