API Platform

API Overview

The Mossland API uses /v1 audio endpoints. You call the endpoint that matches the capability you need, select a model with model, and receive results via a synchronous response, an asynchronous task, or an explicit status query.

Core concepts

  • Endpoint – The interface entry point you request, for example POST /v1/audio/speech.
  • model – Specifies the model to invoke, for example moss-tts; /v1 uses a single model field to name the model.
  • delivery_methodaudio returns the audio directly; url returns JSON with a result URL.
  • response_format – The audio encoding format, such as mp3 / wav; defaults to mp3.
  • async / webhook_url – Pass async=true to create an asynchronous task; once it reaches a terminal state, the result is delivered to webhook_url.
  • task_id – The server returns a task_id for asynchronous tasks, used to query status and results.

Endpoint catalog

EndpointDescriptionSyncAsync
GET /v1/modelsList available models-
POST /v1/filesUpload a file and obtain a file_id-
GET /v1/filesList files-
GET /v1/files/{file_id}Get file details-
DELETE /v1/files/{file_id}Delete a file-
POST /v1/audio/speechSingle-speaker text-to-speech
POST /v1/audio/speech/speakersMulti-speaker dialogue speech generation
POST /v1/audio/voice/generationsVoice / speech generation
GET /v1/audio/voicesList voices-
POST /v1/audio/voicesCreate / clone a voice-
POST /v1/audio/transcriptionsAudio transcription (including multi-speaker)
GET /v1/audio/tasks/{task_id}Query a general audio task-