{
"model": "gpt-4o-audio-preview",
"modalities": [
"text",
"audio"
],
"audio": {
"voice": "alloy",
"format": "wav"
},
"messages": [
{
"role": "user",
"content": "hello"
}
]
}curl --location --request POST 'https://api.302.ai/v1/chat/completions' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer ' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "gpt-4o-audio-preview",
"modalities": [
"text",
"audio"
],
"audio": {
"voice": "alloy",
"format": "wav"
},
"messages": [
{
"role": "user",
"content": "hello"
}
]
}'{
"id": "chatcmpl-Cx5qf8QgUbf1yIHPdZ08WFEFxrVza",
"object": "chat.completion",
"created": 1768199869,
"model": "gpt-4o-audio-preview",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": null,
"refusal": null,
"audio": {
"id": "audio_696496be735481908601f407fca4eb21",
"data": "",
"expires_at": 1768203470,
"transcript": "Hello! How can I assist you today?"
},
"annotations": []
},
"logprobs": null,
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 8,
"completion_tokens": 54,
"total_tokens": 62,
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0,
"text_tokens": 8,
"image_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 37,
"accepted_prediction_tokens": 0,
"rejected_prediction_tokens": 0,
"text_tokens": 17
}
},
"system_fingerprint": "fp_a1c804aea4"
}