Apple introduced API that enables recording audio from other apps or the entire system in macOS 14.4, but it's poorly documented and there's no sample code available, so I decided to fix that: https://github.com/insidegui/AudioCap
GitHub - insidegui/AudioCap: Sample code for recording system audio on macOS 14.4+

Sample code for recording system audio on macOS 14.4+ - insidegui/AudioCap

GitHub
@_inside I would love to see DevPubs integrate community stuff like this into the docs