External Media - Start, End of Stream

Hello! I am implementing an AMD algorithm using the ARI external media functionality and I have a question about how I can identify the start and end of an audio stream? From what I understand it will depend on the audio format, right? I’m initially thinking of using the ulaw format for the audio. I would appreciate any guidance.

There is no metadata in a µ-Law stream. Every octet of it is an audio sample.

ARI does, however, have standard RTP wrapped around that.

Got it, I was wondering if Asterisk/ARI added something additional to the audio stream. Thanks for the reference.