Search...
Menu

Audio Transcription (OpenAI)

Transcribe audio into text while preserving the original language.

Request

Item Description
Method POST
Path /v1/audio/transcriptions
Gateway URL https://ailink.nativex.com
Authentication Authorization: Bearer sk-xxxx; replace the placeholder with your API Key
Request format multipart/form-data

Replace MODEL_ID with a model from the Model Marketplace that supports this endpoint. Available models, parameters, and permissions depend on your account.

Parameters

Parameter Location Type Required Description
file Body file Yes Local audio file
model Body string Yes A speech model that supports this operation
prompt Body string No Context to assist recognition
response_format Body string No Legacy endpoints support json, text, srt, verbose_json, and vtt. Available formats depend on the model.
temperature Body number No Sampling parameter; supported values depend on the model
language Body string No ISO-639-1 language code, such as zh or en
timestamp_granularities[] Body string[] No Timestamp granularity, such as word or segment. Requires model and response-format support.
Upload files with -F so the client generates the multipart boundary automatically. Do not manually set Content-Type: application/json.

Example

curl -X POST 'https://ailink.nativex.com/v1/audio/transcriptions' \
  -H 'Authorization: Bearer sk-xxxx' \
  -F 'file=@audio.mp3' \
  -F 'model=MODEL_ID' \
  -F 'response_format=json'

Response

The following is a simplified response for readability. IDs, URLs, text, and usage values are illustrative.

{
  "text": "Hello, welcome to AiLink."
}
Field or result Description
text Recognized or translated text. Non-JSON formats return plain text or subtitles directly.

Error handling

For unsuccessful responses, check the HTTP status and error body first. Verify the API Key, model name, account balance, and parameters. If rate limited, reduce concurrency and retry later.

Last modified: 2026-11-17