Skip to content

Webhook Events

STT API

These are the available events for STT API.

STT Completed

Event Type: stt.jobs.completed

This event is triggered when an STT job is completed.

Properties
Name Type Description
job_id string(uuid) Unique Identifier of a job.
created_at string(date-time) The time when the job was created.
modified_at string(date-time) The time when the job was last modified.
request - Request submitted for the STT job.
» label string An optional label to give to the job.
» uri string An URI to the request payload. Either uri or data must be present at the request but not both.
» data string The audio data in base64 format. Either uri or data must be present at the request but not both.
» duration number The duration of the audio in second.
» mime_type string Mime Type of the audio.
» sample_rate integer Sample rate of the audio.
» channels integer Number of channels in the audio.
result - Result of an STT job.
» data array Transcriptions of the audio
»» transcript string Text resulting from the transcription process.
»» final boolean Indicates that the piece of transcription is complete and is not cut in the middle of a sentence.
»» time_start number Starting time relative to the start of the audio.
»» time_end number Ending time relative to the start of the audio.
»» channel integer Channel in which the result is transcribed from.
job_config - Configuration for the job execution.
» engine string The name of STT model to use.
» wait boolean If set to true, the request blocks until the execution is finished.
» include_filler boolean Include fillers returned from engine in the result.
» include_partial_results boolean Include result that are partially complete.
model - Selected STT model.
» name string Name of the model.
» label string Human readable name of the model.
» language string Human-readable language of the model.
» domain string The specific area or topic covered by the STT model.
» acoustic string The optimal audio source which gives best recognition result.
» channels integer The optimal number of the channels for the audio data.
» samplerate integer The optimal sample rate for the audio data.
Example
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{
  "job_id": "063c64da-180d-731e-8000-d11a28529080",
  "created_at": "2023-01-17T14:26:25.505439",
  "modified_at": "2023-01-17T14:26:26.619771",
  "model": {
    "name": "stt-general",
    "label": "STT General",
    "domain": "general",
    "acoustic": "recording",
    "channels": 1,
    "language": "Bahasa Indonesia",
    "samplerate": 16000
  },
  "result": {
    "data": [
      {
        "final": true,
        "channel": 0,
        "time_end": 6.470000009536743,
        "time_start": 1,
        "transcript": "hasil dari pekerjaan ini cukup memuaskan",
        "speaker_tag": 1
      }
    ]
  },
  "request": {
    "uri": "https://example.domain.name/media/example_audio.wav",
    "label": "Example audio",
    "channels": 1,
    "duration": 6.766625,
    "mime_type": "audio/wav",
    "sample_rate": 8000
  },
  "job_config": {
    "wait": false,
    "engine": "stt-general",
    "speaker_count": 1,
    "include_filler": false,
    "include_partial_results": false
  }
}

STT Failed

Event Type: stt.jobs.failed

This event is triggered when an STT job is failed to be executed.

Properties
Name Type Description
job_id string(uuid) Unique Identifier of a job.
created_at string(date-time) The time when the job was created.
modified_at string(date-time) The time when the job was last modified.
request - Request submitted for the STT job.
» label string An optional label to give to the job.
» uri string An URI to the request payload. Either uri or data must be present at the request but not both.
» data string The audio data in base64 format. Either uri or data must be present at the request but not both.
» duration number The duration of the audio in second.
» mime_type string Mime Type of the audio.
» sample_rate integer Sample rate of the audio.
» channels integer Number of channels in the audio.
result - Result of an STT job.
» error string The short summary of the error.
job_config - Configuration for the job execution.
» engine string The name of STT model to use.
» wait boolean If set to true, the request blocks until the execution is finished.
» include_filler boolean Include fillers returned from engine in the result.
» include_partial_results boolean Include result that are partially complete.
model - Selected STT model.
» name string Name of the model.
» label string Human readable name of the model.
» language string Human-readable language of the model.
» domain string The specific area or topic covered by the STT model.
» acoustic string The optimal audio source which gives best recognition result.
» channels integer The optimal number of the channels for the audio data.
» samplerate integer The optimal sample rate for the audio data.
Example
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{
  "job_id": "063c64da-180d-731e-8000-d11a28529080",
  "created_at": "2023-01-17T14:26:25.505439",
  "modified_at": "2023-01-17T14:26:26.619771",
  "model": {
    "name": "stt-general",
    "label": "STT General",
    "domain": "general",
    "acoustic": "recording",
    "channels": 1,
    "language": "Bahasa Indonesia",
    "samplerate": 16000
  },
  "result": {
    "error": "internal_error"
  },
  "request": {
    "uri": "https://example.domain.name/media/example_audio.wav",
    "label": "Example audio",
    "channels": 1,
    "duration": 6.766625,
    "mime_type": "audio/wav",
    "sample_rate": 8000
  },
  "job_config": {
    "wait": false,
    "engine": "stt-general",
    "speaker_count": 1,
    "include_filler": false,
    "include_partial_results": false
  }
}

TTS API

These are the available events for TTS API.

TTS Completed

Event Type: tts.jobs.completed

This event is triggered when a TTS job is completed.

Properties
Name Type Description
job_id string(uuid) Unique Identifier of a job.
created_at string(date-time) The time when the job was created.
modified_at string(date-time) The time when the job was last modified.
request - Request submitted for the TTS job.
» label string An optional label to give to the job.
» text string An URI to the request payload. Either uri or data must be present at the request but not both.
result - Result of an TTS job.
» path string A signed url to retrieve the synthesized audio. This url expires in 7 days.
» format string An enumeration of wav, mp3 or opus.
» duration number The duration of the synthesized speech audio.
» samplerate integer The sample rate of the synthesized speech audio.
» channels integer The number of channels of the synthesized speech audio.
job_config - Configuration for the job execution.
» model string The name of TTS model to use.
» wait boolean If set to true, the request blocks until the execution is finished.
» pitch number Include fillers returned from engine in the result.
» tempo number The tempo of the generated speech audio.
» audio_format string The file format of the generated speech audio.
model - Selected TTS model.
» name string Name of the model.
» label string Human readable name of the model.
» language string Human-readable language of the model.
» domain string The pronunciation style of the TTS model.
» voice string The alias for the TTS model persona.
» gender string The gender of the TTS model.
» channels integer The optimal number of the channels for the audio data.
» samplerate integer The optimal sample rate for the audio data.
Example
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
{
  "job_id": "2fec34e1efb146f7a7431cb35b64550d",
  "status": "complete",
  "created_at": "2019-08-24T14:15:22Z",
  "modified_at": "2019-08-24T14:15:22Z",
  "request": {
    "label": "string",
    "text": "Hasil akhir dari pekerjaan ini cukup memuaskan"
  },
  "result": {
    "path": "<Signed URI to download audio file>",
    "format": "opus",
    "duration": 1.506,
    "samplerate": 48000,
    "channels": 1
  },
  "job_config": {
    "model": "tts-dimas-formal",
    "wait": false,
    "pitch": 0,
    "tempo": 1,
    "audio_format": "opus"
  },
  "model": {
    "name": "tts-dimas-formal",
    "label": "TTS Dimas Formal",
    "language": "Bahasa Indonesia",
    "domain": "formal",
    "voice": "Dimas",
    "gender": "male",
    "channels": 1,
    "samplerate": 48000
  }
}

TTS Failed

Event Type: tts.jobs.failed

This event is triggered when a TTS job is failed to be executed.

Properties
Name Type Description
job_id string(uuid) Unique Identifier of a job.
created_at string(date-time) The time when the job was created.
modified_at string(date-time) The time when the job was last modified.
request - Request submitted for the TTS job.
» label string An optional label to give to the job.
» text string An URI to the request payload. Either uri or data must be present at the request but not both.
result - Result of an TTS job.
» error string The short summary of the error.
job_config - Configuration for the job execution.
» model string The name of TTS model to use.
» wait boolean If set to true, the request blocks until the execution is finished.
» pitch number Include fillers returned from engine in the result.
» tempo number The tempo of the generated speech audio.
» audio_format string The file format of the generated speech audio.
model - Selected TTS model.
» name string Name of the model.
» label string Human readable name of the model.
» language string Human-readable language of the model.
» domain string The pronunciation style of the TTS model.
» voice string The alias for the TTS model persona.
» gender string The gender of the TTS model.
» channels integer The optimal number of the channels for the audio data.
» samplerate integer The optimal sample rate for the audio data.
Example
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{
  "job_id": "2fec34e1efb146f7a7431cb35b64550d",
  "status": "failed",
  "created_at": "2019-08-24T14:15:22Z",
  "modified_at": "2019-08-24T14:15:22Z",
  "request": {
    "label": "string",
    "text": "Hasil akhir dari pekerjaan ini cukup memuaskan"
  },
  "result": {
    "error": "internal_error"
  },
  "job_config": {
    "model": "tts-dimas-formal",
    "wait": false,
    "pitch": 0,
    "tempo": 1,
    "audio_format": "opus"
  },
  "model": {
    "name": "tts-dimas-formal",
    "label": "TTS Dimas Formal",
    "language": "Bahasa Indonesia",
    "domain": "formal",
    "voice": "Dimas",
    "gender": "male",
    "channels": 1,
    "samplerate": 48000
  }
}