Skip to main content

Qwen-Audio-TTS HarmonyOS SDK

Prerequisites

  1. Obtain and configure an API key. Do not hardcode a long-lived API key in a mobile app. We recommend generating a temporary API key on your application server and sending it to the client.
  2. Download the latest SDK package. Extract the package, copy entry/libs/neonui.har to the entry/libs directory of your application, and add the dependency to entry/oh-package.json5:
{
  "dependencies": {
    "neonui": "file:libs/neonui.har"
  }
}

Quick start

Open the sample project from the SDK package in DevEco Studio. The sample page is entry/src/main/ets/pages/dashscope/DashCosyVoiceStreamTtsPage.ets. Configure an API key and run the project. Use model qwen-audio-3.0-tts-flash in the example.

Reference