---
title: OpenAI Transkription Sprache zu Text | RunAPI
description: Verwenden Sie den Endpunkt „Sprache zu Text", um ein Ergebnis in derselben
  Antwort zu empfangen.
url: https://runapi.ai/de/docs/api/openai-transcription/speech-to-text.md
canonical: https://runapi.ai/de/docs/api/openai-transcription/speech-to-text
locale: de
---

> HTML-Version: https://runapi.ai/de/docs/api/openai-transcription/speech-to-text
> Website-Index für KI-Agenten: https://runapi.ai/llms.txt

# OpenAI Transkription Sprache zu Text

## Übersicht

Verwenden Sie den Endpunkt „Sprache zu Text" und lesen Sie das Ergebnis aus derselben Antwort aus.

### Schnellstart

1. Erstellen Sie einen API-Schlüssel und setzen Sie ihn als RUNAPI_API_KEY.
2. Eine POST-Anfrage senden, deren Körper dem Anfrage-Schema entspricht.
3. Das Ergebnis aus dem erfolgreichen Antwortkörper lesen.

## Endpunkt

POST /v1/audio/transcriptions

Basis-URL: https://runapi.ai

API-Version: v1

Authentifizierung: Authorization: Bearer YOUR_API_TOKEN

## Unterstützte Modelle

Öffnen Sie eine Modellseite für aktuelle Preise, Ratenlimits und Details zur kommerziellen Nutzung.

- [gpt-transcribe](https://runapi.ai/de/models/openai-transcription/gpt-transcribe)
- [whisper-1](https://runapi.ai/de/models/openai-transcription/whisper-1)

## Anfrage-Schema

Nur die für diesen Endpunkt deklarierten Felder senden.

### gpt-transcribe

```json
{
  "file": {
    "description": "Audio-Datei-Upload, bis zu 25 MB.",
    "required": true,
    "type": "string"
  },
  "keywords": {
    "description": "Begriffe, die zusätzliche Erkennungshinweise erhalten sollen.",
    "items": {
      "type": "string"
    },
    "type": "array"
  },
  "language": {
    "description": "Audiosprache als ISO-639-1-Code.",
    "type": "string"
  },
  "languages": {
    "description": "Kandidaten-Audiosprachen als ISO-639-1-Codes.",
    "items": {
      "type": "string"
    },
    "type": "array"
  },
  "model": {
    "description": "Transkriptionsmodell.",
    "enum": [
      "gpt-transcribe"
    ],
    "type": "string"
  },
  "prompt": {
    "description": "Optionaler Text, der den Transkriptionsstil und das Vokabular leitet.",
    "type": "string"
  },
  "response_format": {
    "description": "Format des Antwortkörpers.",
    "enum": [
      "json",
      "text"
    ],
    "type": "string"
  },
  "stream": {
    "description": "Ob eine gestreamte Antwort angefordert werden soll, sofern unterstützt.",
    "type": "boolean"
  },
  "temperature": {
    "description": "Sampling-Temperatur von 0 bis 1.",
    "max": 1,
    "min": 0,
    "type": "number"
  }
}
```

### whisper-1

```json
{
  "file": {
    "description": "Audio-Datei-Upload, bis zu 25 MB.",
    "required": true,
    "type": "string"
  },
  "language": {
    "description": "Audiosprache als ISO-639-1-Code.",
    "type": "string"
  },
  "model": {
    "description": "Transkriptionsmodell.",
    "enum": [
      "whisper-1"
    ],
    "type": "string"
  },
  "prompt": {
    "description": "Optionaler Text, der den Transkriptionsstil und das Vokabular leitet.",
    "type": "string"
  },
  "response_format": {
    "description": "Format des Antwortkörpers.",
    "enum": [
      "json",
      "text",
      "srt",
      "verbose_json",
      "vtt"
    ],
    "type": "string"
  },
  "stream": {
    "description": "Ob eine gestreamte Antwort angefordert werden soll, sofern unterstützt.",
    "type": "boolean"
  },
  "temperature": {
    "description": "Sampling-Temperatur von 0 bis 1.",
    "max": 1,
    "min": 0,
    "type": "number"
  },
  "timestamp_granularities": {
    "description": "Zeitstempeldetail, das in ausführlichen JSON-Antworten enthalten ist.",
    "items": {
      "enum": [
        "word",
        "segment"
      ],
      "type": "string"
    },
    "max_items": 2,
    "type": "array"
  }
}
```

## Erfolgsantwort

HTTP 200 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "oneOf": [
    {
      "properties": {
        "duration": {
          "type": "number"
        },
        "language": {
          "type": "string"
        },
        "logprobs": {
          "items": {
            "properties": {
              "bytes": {
                "items": {
                  "type": "integer"
                },
                "type": "array"
              },
              "logprob": {
                "type": "number"
              },
              "token": {
                "type": "string"
              }
            },
            "type": "object",
            "unevaluatedProperties": false
          },
          "type": "array"
        },
        "segments": {
          "items": {
            "properties": {
              "avg_logprob": {
                "type": "number"
              },
              "compression_ratio": {
                "type": "number"
              },
              "end": {
                "type": "number"
              },
              "id": {
                "type": "integer"
              },
              "no_speech_prob": {
                "type": "number"
              },
              "seek": {
                "type": "integer"
              },
              "start": {
                "type": "number"
              },
              "temperature": {
                "type": "number"
              },
              "text": {
                "type": "string"
              },
              "tokens": {
                "items": {
                  "type": "integer"
                },
                "type": "array"
              }
            },
            "type": "object",
            "unevaluatedProperties": false
          },
          "type": "array"
        },
        "task": {
          "type": "string"
        },
        "text": {
          "type": "string"
        },
        "usage": {
          "properties": {
            "input_token_details": {
              "properties": {
                "audio_tokens": {
                  "type": "integer"
                },
                "text_tokens": {
                  "type": "integer"
                }
              },
              "type": "object",
              "unevaluatedProperties": false
            },
            "input_tokens": {
              "type": "integer"
            },
            "output_tokens": {
              "type": "integer"
            },
            "seconds": {
              "type": "number"
            },
            "total_tokens": {
              "type": "integer"
            },
            "type": {
              "type": "string"
            }
          },
          "type": "object",
          "unevaluatedProperties": false
        },
        "words": {
          "items": {
            "properties": {
              "end": {
                "type": "number"
              },
              "start": {
                "type": "number"
              },
              "word": {
                "type": "string"
              }
            },
            "required": [
              "word",
              "start",
              "end"
            ],
            "type": "object",
            "unevaluatedProperties": false
          },
          "type": "array"
        }
      },
      "required": [
        "text"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    {
      "type": "string"
    }
  ]
}
```

### Antwortbeispiel

```json
{
  "text": "Welcome to RunAPI."
}
```

## Fehler

HTTP 401 - POST /v1/audio/transcriptions

Diese Antwort hat keinen Body.

## Fehler

HTTP 400 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "invalid_request",
    "message": "Invalid request"
  }
}
```

## Fehler

HTTP 402 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "insufficient_balance",
    "message": "Insufficient balance"
  }
}
```

## Fehler

HTTP 429 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "api_token_credit_limit_exceeded",
    "message": "API key credit limit exceeded"
  }
}
```

## Fehler

HTTP 409 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "request_conflict",
    "message": "The request uses features that are not supported for the selected model"
  }
}
```

## Fehler

HTTP 429 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "rate_limited",
    "message": "Rate limit reached. Please retry later."
  }
}
```

## Fehler

HTTP 503 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "error": {
    "code": "service_unavailable",
    "message": "Service under maintenance, please try again later"
  }
}
```

## Fehler

HTTP 504 - POST /v1/audio/transcriptions

### Antwort-Schema

```json
{
  "properties": {
    "billing": {
      "properties": {
        "refund": {
          "oneOf": [
            {
              "properties": {
                "refunded_at": {
                  "type": "string"
                }
              },
              "required": [
                "refunded_at"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "reservation": {
          "oneOf": [
            {
              "properties": {
                "amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "amount_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        },
        "settlement": {
          "oneOf": [
            {
              "properties": {
                "amount_micro_cents": {
                  "type": "integer"
                },
                "charged_amount_cents": {
                  "type": "integer"
                }
              },
              "required": [
                "charged_amount_cents",
                "amount_micro_cents"
              ],
              "type": "object",
              "unevaluatedProperties": false
            },
            {
              "enum": [
                null
              ]
            }
          ]
        }
      },
      "required": [
        "reservation",
        "settlement",
        "refund"
      ],
      "type": "object",
      "unevaluatedProperties": false
    },
    "error": {
      "properties": {
        "code": {
          "type": "string"
        },
        "limit_cents": {
          "type": "integer"
        },
        "message": {
          "type": "string"
        },
        "reset_at": {
          "format": "date-time",
          "type": [
            "string",
            "null"
          ]
        },
        "used_cents": {
          "type": "integer"
        },
        "window": {
          "enum": [
            "1h",
            "1d",
            "7d",
            "daily",
            "weekly",
            "monthly",
            "lifetime"
          ],
          "type": "string"
        }
      },
      "required": [
        "code",
        "message"
      ],
      "type": "object",
      "unevaluatedProperties": false
    }
  },
  "required": [
    "error"
  ],
  "type": "object",
  "unevaluatedProperties": false
}
```

### Antwortbeispiel

```json
{
  "billing": {
    "refund": null,
    "reservation": null,
    "settlement": null
  },
  "error": {
    "code": "timeout_error",
    "message": "The request timed out"
  }
}
```

## Generierte Code-Beispiele

Verwende cURL direkt oder installiere ein SDK für deine Programmiersprache. Jedes Beispiel übermittelt die in dieser Referenz gezeigte validierte Anfrage.

### curl

```curl
curl -X POST https://runapi.ai/v1/audio/transcriptions \
  -H 'Authorization: Bearer YOUR_API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"file":"audio.mp3","model":"whisper-1","response_format":"json"}'
```

### javascript

#### Installieren

```bash
npm install @runapi.ai/openai-transcription
```

```javascript
import { OpenaiTranscriptionClient } from "@runapi.ai/openai-transcription";

const client = new OpenaiTranscriptionClient({ apiKey: process.env.RUNAPI_API_KEY });
const result = await client.speechToText.run({
  "file": "audio.mp3",
  "model": "whisper-1",
  "response_format": "json"
});
```

### python

#### Installieren

```bash
pip install runapi-openai-transcription
```

```python
import os
from runapi.openai_transcription import OpenaiTranscriptionClient

client = OpenaiTranscriptionClient(api_key=os.environ["RUNAPI_API_KEY"])
result = client.speech_to_text.run(
  file="audio.mp3",
  model="whisper-1",
  response_format="json"
)
```

### go

#### Installieren

```bash
go get github.com/runapi-ai/openai-transcription-sdk/go@latest
```

```go
package main

import (
  "context"
  "log"
  "os"

  "github.com/runapi-ai/core-sdk/go/option"
  openaitranscription "github.com/runapi-ai/openai-transcription-sdk/go/openaitranscription"
)

func main() {
  client, err := openaitranscription.NewClient(option.WithAPIKey(os.Getenv("RUNAPI_API_KEY")))
  if err != nil {
    log.Fatal(err)
  }

  result, err := client.SpeechToText.Run(context.Background(), openaitranscription.SpeechToTextParams{
    File: "audio.mp3",
    Model: "whisper-1",
    ResponseFormat: "json",
  })
  if err != nil {
    log.Fatal(err)
  }
  _ = result
}
```

### ruby

#### Installieren

```bash
gem install runapi-openai-transcription
```

```ruby
require "runapi/openai_transcription"

client = RunApi::OpenaiTranscription::Client.new(api_key: ENV.fetch("RUNAPI_API_KEY"))
result = client.speech_to_text.run(
  file: "audio.mp3",
  model: "whisper-1",
  response_format: "json"
)
```

### java

#### Installieren

```kotlin
implementation("ai.runapi:runapi-openai-transcription")
```

```java
import ai.runapi.openaitranscription.OpenaiTranscriptionClient;
import ai.runapi.openaitranscription.types.SpeechToTextParams;
import ai.runapi.openaitranscription.types.TranscriptionResponse;

public final class Example {
  public static void main(String[] args) {
    OpenaiTranscriptionClient client = OpenaiTranscriptionClient.builder()
        .apiKey(System.getenv("RUNAPI_API_KEY"))
        .build();
    TranscriptionResponse result = client.speechToText().run(
        SpeechToTextParams.builder()
        .file("audio.mp3")
        .model("whisper-1")
        .responseFormat("json")
            .build()
    );
  }
}
```

### php

#### Installieren

```bash
composer require runapi-ai/openai-transcription
```

```php
<?php

require __DIR__ . '/vendor/autoload.php';

use RunApi\Core\ClientOptions;
use RunApi\OpenaiTranscription\OpenaiTranscriptionClient;

$client = new OpenaiTranscriptionClient(new ClientOptions(apiKey: getenv('RUNAPI_API_KEY')));
$result = $client->speechToText->run([
  "file" => "audio.mp3",
  "model" => "whisper-1",
  "response_format" => "json"
]);
```

## Verwandte Anleitungen

- [Authentifizierung](https://runapi.ai/de/docs/guides/authentication.md)
- [Schnellstart](https://runapi.ai/de/docs/guides/task-api/quickstart.md)

---

## Mehr von RunAPI

- [Startseite](https://runapi.ai/de/.md)
- [Modellkatalog](https://runapi.ai/de/models.md)
- [Preise](https://runapi.ai/de/pricing.md)
- [Anbieter](https://runapi.ai/de/models)
- [Dokumentation](https://runapi.ai/de/docs/guides)
- [SDKs](https://runapi.ai/de/sdk.md)
- [CLI](https://runapi.ai/de/cli.md)
- [MCP Server](https://runapi.ai/de/mcp.md)
- [Claude Code vs Cursor](https://runapi.ai/de/claude-code-vs-cursor.md)
- [Cursor API-Einrichtung](https://runapi.ai/de/cursor-api-setup.md)
- [RunAPI vs OpenRouter](https://runapi.ai/de/openrouter-alternative.md)
- [Enterprise](https://runapi.ai/de/contact.md)
- [Kontakt](https://runapi.ai/de/contact.md)
- [Bedingungen](https://runapi.ai/de/terms.md)
- [Datenschutz](https://runapi.ai/de/privacy.md)
- [Website-Index für KI-Agenten](https://runapi.ai/llms.txt)

Kontakt: contact@runapi.ai

## Strukturierte Daten

```json
[
  {
    "@context": "https://schema.org",
    "inLanguage": "de",
    "@type": "WebSite",
    "name": "RunAPI",
    "url": "https://runapi.ai/de",
    "potentialAction": {
      "@type": "SearchAction",
      "target": {
        "@type": "EntryPoint",
        "urlTemplate": "https://runapi.ai/de/models?q={search_term_string}"
      },
      "query-input": "required name=search_term_string"
    }
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "de",
    "@type": "Organization",
    "name": "RunAPI",
    "url": "https://runapi.ai/de",
    "logo": {
      "@type": "ImageObject",
      "url": "https://runapi.ai/deicon.svg"
    },
    "sameAs": [
      "https://github.com/runapi-ai"
    ]
  },
  {
    "@context": "https://schema.org",
    "inLanguage": "de",
    "@type": "TechArticle",
    "headline": "OpenAI Transkription Sprache zu Text",
    "description": "Verwenden Sie den Endpunkt „Sprache zu Text\", um ein Ergebnis in derselben Antwort zu empfangen.",
    "url": "https://runapi.ai/de/docs/api/openai-transcription/speech-to-text",
    "mainEntityOfPage": "https://runapi.ai/de/docs/api/openai-transcription/speech-to-text"
  }
]
```
