Before app launch
Run these commands from project root to generate necessary files:
flutter pub getand
dart run build_runner build --delete-conflicting-outputsThis app uses the ElevenLabs TTS API to pronounce vocabulary words.
An API key is required for text-to-speech functionality to work.
If no API key is provided, the app will not be able to announce words.
You can provide the API key via an environment variable. Example:
flutter run --dart-define=TTS_API_KEY=your_api_keyReplace your_api_key with the actual key obtained from https://elevenlabs.io.
How to get an API key:
- Go to https://elevenlabs.io/ and sign up.
- Go to https://elevenlabs.io/app/settings/api-keys and create your API key.
- Run flutter app as described above.
- Here is the documentation for the endpoint used in this app to convert text to speech: https://elevenlabs.io/docs/api-reference/text-to-speech/convert
- Here is pricing: https://elevenlabs.io/pricing/api
At the time of writing this README, ElevenLabs offers a free tier for API usage.