Skip to content
A kotlin DSL for SSML, supports Actions-on-google.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Build Status Download


A kotlin library that provides DSL to build SSML. Supports Actions on Google elements.

Get started

This goes into your build.gradle.

dependencies {
  compile 'com.mirego.dsl:ssml:1.1'


val ssml = speak {
  +"Here are "; sayAs(interpretAs = CHARACTERS) { +"SSML" }; +" samples.\n"
  +"I can pause "; `break`(time = "3s"); +".\n"
  +"I can play a sound"; audio(src = "") { +"didn't get your MP3 audio file" }; +".\n"
  +"I can speak in cardinals. Your number is "; sayAs(interpretAs = CARDINAL) { +"10" };+".\n"
  +"Or I can speak in ordinals. You are "; sayAs(interpretAs = ORDINAL) { +"10" }; +" in line.\n"
  +"Or I can even speak in digits. The digits for ten are "; sayAs(interpretAs = CHARACTERS) { +"10" }; +".\n"
  +"I can also substitute phrases, like the "; sub(alias = "World Wide Web Consortium") { +"W3C" }; +".\n"
  +"Finally, I can speak a paragraph with two sentences.\n"
  p { s { +"This is sentence one." }; s { +"This is sentence two." } }; +"\n"

About Mirego

Mirego is a team of passionate people who believe that work is a place where you can innovate and have fun. We’re a team of talented people who imagine and build beautiful Web and mobile applications. We come together to share ideas and change the world.

We also love open-source software and we try to give back to the community as much as we can.

You can’t perform that action at this time.