Skip to main content
<DailyAudioTrack sessionId={sessionId} /> Use this component to compose a custom audio arrangement in a Daily call.

Props

sessionId
string
required
The participant’s session_id for which the audio track should be played.
onPlayFailed
Function
Callback when an <audio> tag fails to play().
type
'audio' | 'screenAudio' | 'rmpAudio' | string
default:"'audio'"
The participant’s track type to play. In addition to the built-in track types, you can pass the trackName of a custom audio track started via startCustomTrack().

Data attributes

DailyAudioTrack renders a couple of dynamic data attributes:

Example

To play a custom audio track, pass its trackName as the type:

See also