project_export_audio
Export an Audacity project's audio to a file. Choose the output format via the file extension (wav, mp3, ogg, flac, aiff) and set the channel count.
Instructions
Export the project audio to a file. Format is determined by file extension.
MANDATORY: ALWAYS tell the user where the file will be saved BEFORE exporting. Example: "I'll save your audio to C:\Users\Name\Music\file.mp3"
NEVER save directly to the user's home folder (e.g. ~/file.mp3 or C:\Users\Name\file.mp3). ALWAYS save to a subfolder. If the user doesn't specify a path, call get_default_export_folder to get their Music folder and save there. Acceptable locations:
Music folder: ~/Music/file.mp3
Documents folder: ~/Documents/file.mp3
Desktop: ~/Desktop/file.mp3 NEVER save to the home folder root — this clutters the user's home directory.
Args: path: Absolute path for exported file. Extension determines format (wav, mp3, ogg, flac, aiff). num_channels: Number of channels (1=mono, 2=stereo). Default: 2
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| num_channels | No |