Skip to main content
Use Ambient APIs with input_type set to audio_file when your application already has a WAV recording of the visit. Common cases include telephony archives, device recordings, and repeatable staging fixtures. First, authenticate, create an Ambient session, and seed visit context. Then, mint a one-time upload URL from the shared Get audio file upload URL endpoint using your Ambient ambient_session_id, and PUT one WAV with both signed headers. You do not need to open /ws/stream. Suki starts processing after the upload succeeds.
Important:
  • Do not call the end session endpoint for this flow.
  • Upload exactly one WAV file. Processing starts when the PUT succeeds.
For a comparison of pre-recorded audio input across Ambient and Form filling, refer to:
Applies to: Ambient APIs.
  • Create with input_type audio_file before you mint the upload URL.
  • Mint and PUT use the shared Get audio file upload URL endpoint with this Ambient ambient_session_id.
  • Do not open /ws/stream, and do not call end session to start processing.
The typical Ambient audio_file flow is: Flowchart: Create audio_file, Seed visit context, GET file-uploadurl, PUT WAV, Poll status, Retrieve note. Flowchart: Create audio_file, Seed visit context, GET file-uploadurl, PUT WAV, Poll status, Retrieve note.

Prerequisites

Build the upload flow

Your application should connect create, context, upload, and note retrieval in this order.
1

Create the Ambient Session with Audio File Input

Call POST Create ambient session with input_type set to audio_file. Store ambient_session_id and note_id.
input_type is fixed for the life of the session. Create a new session if you need stream or transcript instead.
2

Seed Ambient Session Context

Send patient, visit, specialty, and section context the same way you do for a live stream session. Finish context before you mint the upload URL when your product needs those fields.Refer to Provide visit context.
3

Get the Upload URL

Call GET Get audio file upload URL with this Ambient ambient_session_id.
Read presigned_url_response.url and expiry_in_minutes (example: 15 minutes). Finish the upload before the URL expires.
4

PUT the WAV File

Upload the file to the returned URL with both signed headers:Upload one WAV per session, at most 500 MB. Reusing the URL to overwrite the object returns HTTP 412.
Do not call end session. The successful PUT starts processing.
5

Wait for Processing, Then Retrieve Outputs

Poll Ambient session status or wait for your webhook. Retrieve content only when status is completed.Recording retrieval works for audio_file sessions. Refer to Use ambient session recordings and Retrieve ambient content.

Handle the session status

After the PUT succeeds, the note is not ready yet. Poll status until Suki returns a final outcome, or wait for your configured webhook. Refer to Track note generation status for the full polling flow.

Complete staging scripts

Use these scripts on staging after you replace partner credentials and point AUDIO_PATH at a WAV file (at most 500 MB). Do not call end session.
Ambient audio_file

Troubleshooting

Upload usually fails when the session was not created as audio_file, when you mix Ambient and Form filling session IDs, or when you treat a second mint or overwrite PUT as a retry.
The session was not created with input_type audio_file. Create a new Ambient session with that value, then mint again.
Input was already submitted for this session, or you tried to overwrite the uploaded object. Upload one WAV per session. Create a new session for another file.
Audio file upload is disabled for the environment. Contact support if you need the path enabled.
Pass the Ambient ambient_session_id from Ambient create. Do not pass a Form filling session id into Ambient upload or retrieve calls.
Do not call end session for audio_file. Processing starts when the PUT succeeds. End belongs to the live stream path.

Available cookbooks

Next steps

Get audio file upload URL - Request, upload contract, and error ids. Submit a finished transcript - Use when you already have text instead of audio. Track note generation status - Poll until processing finishes. Retrieve ambient content - Read the generated note after processing. Session input types - Compare live stream, audio file, and transcript.
Last modified on November 24, 2026