Tapra CLI
Derja transcription and voiceovers from your terminal
One command for scripts, CI and AI agents: transcripts and subtitles of Derja mixed with French, Arabic and English, live transcription, natural Tunisian voiceovers, Arabizi and translation.
Install the tapra command
Same commands from npm and pip. Needs Node.js 22+ or Python 3.10+.
npm install -g @tapra/sdkQuick start
Up and running in five steps
Each step is one or two commands. Paid commands print what they cost and the balance left.
- 1
Log in
Paste an API key from the dashboard. It is checked against your account, then saved for every command. In CI, set TAPRA_API_KEY instead.
tapra auth logintapra auth status # key, where it comes from, balance - 2
Transcribe a file
Derja mixed with French and English comes back as spoken. Add --diarize for speakers, and pick text, json, srt or vtt.
tapra transcribe call.mp3tapra transcribe pitch.wav --prompt "Tapra, Ooredoo, Sfax" - 3
Make a voiceover
Arabic script, Arabizi, French or English, in one line, with Tunisian pronunciation. Five voices; --flash is faster and cheaper.
tapra speak "عسلامة، حبيت نتلقاو demain" --voice amal -o hello.wavtapra speak --file script.txt --voice fahmi --flash -o narration.wav - 4
Convert and translate text
Flip Arabizi to Arabic script and back, direction detected. Translate between Derja and English, French or Arabic.
tapra flip "3lech 7abit l9anoun?" # علاش حبيت القانون؟cat comments.txt | tapra flip - --to arabic - 5
Script it, or hand it to an agent
Results go to stdout and cost to stderr. --json gives parseable output, --dry-run shows the request without sending it, and exit codes say what went wrong.
tapra transcribe call.mp3 --json | jq -r '.segments[].text'for f in calls/*.mp3; do tapra transcribe "$f" -o "${f%.mp3}.txt" -q; doneFor Claude Code, Codex or Cursor.
Reference
Commands, options and exit codes
Run tapra <command> --help for every option of a command.
| Command | What it does |
|---|---|
tapra transcribe | Audio or video to text, srt or vtt. Speakers with --diarize.paid |
tapra stream | Live transcription over WebSocket, from a file or stdin.paid |
tapra diarize | Who spoke when, without a transcript.paid |
tapra speak | Tunisian voiceover from text, saved as WAV. --flash for speed.paid |
tapra flip | Arabizi to Arabic script and back, direction detected.paid |
tapra translate | Derja to and from English, French and Arabic.paid |
tapra auth login | Save an API key after checking it against your account. |
tapra auth status | Which key is used, where it comes from, and your balance. |
tapra auth logout | Remove the saved key. |
tapra balance | Your balance in TND. |
tapra pricing | Price per model. |
tapra models | Model IDs for the API. |
tapra voices | The five Tapra voices. |
tapra languages | Translation languages. |
tapra health | API status. |
tapra config show | Print saved settings. |
tapra config set | Save api_url, site_url, voice or output. |
tapra config unset | Remove a setting. |
tapra config path | Where settings are saved. |
tapra completion | Shell completion for bash, zsh, fish or PowerShell. |
| Option | What it does |
|---|---|
--json | Print the full JSON response. |
-q, --quiet | No cost or progress lines on stderr. |
--dry-run | Print the HTTP request, key hidden, and send nothing. |
--api-key <key> | Key for this run only. |
--api-url <url> | Model API address. Default https://api.tapra.tn. |
--timeout <seconds> | Request timeout. Default 300. |
-o, --output <file> | Write the result to a file. Never overwrites without --force. |
| Variable | What it does |
|---|---|
TAPRA_API_KEY | API key. Wins over the saved key; --api-key wins over both. |
TAPRA_API_URL | Model API address. |
TAPRA_OUTPUT | Set to json to make --json the default. |
TAPRA_CONFIG_DIR | Where config.json lives. |
| Code | Meaning |
|---|---|
0 | Done. |
1 | API or network error. |
2 | Bad command, option or file. |
3 | No API key, or the key was refused. |
4 | Balance too low. Top up in the dashboard. |