Browse docs

Station Announcements and TTS

Set up station audio step by step with Google Cloud Text-to-Speech, ElevenLabs or VoiceRSS, then configure playback in Jobs Base.

Station announcements play audio around a configured station from the Dispatch center. You can prepare an MP3 once and reuse it, or connect a service that generates speech for changing text. Jobs Base provides the playback integration; a TTS service and its hosting are separate.

Choose your workflow

What you wantWhat you needJobs Base input
Repeat a fixed announcementAn MP3 on your webspaceApproved audio URL
Generate an announcement with Google Cloud, ElevenLabs or VoiceRSS, then reuse itFollow one provider guide below and upload its MP3Approved audio URL
Read changing text entered in the Dispatch centerA compatible TTS endpoint that returns playable audio, plus any required backend integrationAnnouncement text and a configured TTS URL Template

For a first setup, start with one hosted MP3. This checks the station, permissions and audio playback before adding automatic speech generation.

1. Prepare Jobs Base

  1. Set up the Dispatch center, including its covered jobs and dispatcher access.
  2. Install xSound and start its resource before Jobs Base. The supplied adapter name is xsound.
  3. Open /jobconfig → Jobs Base Configurator → Dispatch & Tracking → Dispatch and find Announcement. Set Enabled to true, Resource to xsound, and choose a radius. The default radius is 65 metres.
  4. Under the same Dispatch settings, edit your Center → Stations and add a target station. Give it a unique ID, its department's exact job name, and either its coordinates or a station POI. The department must be one of that center's Covered jobs.
  5. If using a POI, select one from that job's Dispatch → POIs and use its exact name in the station's poi field. A matching POI's radius overrides the default announcement radius.
  6. Grant the employee Dispatch center permission (21). With the supplied permission settings, announcements also need Dispatch warnings (23). Start a dispatcher shift with Situation control selected; that role includes send_announcements by default.
  7. Save your settings. The supplied centers start with empty station lists, so adding an audio URL alone does not create a target station.

When Config.UseIngameConfigurator is enabled, saved settings take precedence over sky_jobs_base/config/config.lua. Change the effective settings in /jobconfig. If you use file configuration instead, edit the existing Config.Dispatch settings and restart Jobs Base. Preserve the rest of your center and Dispatch configuration.

Playback is positional: nearby players in the same routing bucket can hear it, including players outside the department. A dispatcher working away from the station may not hear the announcement.

2. Create your announcement

Choose one provider. You do not need accounts with all three. Check the provider's current pricing and usage limits before generating speech; Jobs Base does not include provider credits.

Google Cloud Text-to-Speech

Google Cloud can create your announcement as an MP3. Its API is not a direct playback URL: it accepts a POST request and its REST response contains Base64-encoded audio in JSON. See Google's synthesis API.

  1. Open the Google Cloud setup guide. Choose a project, enable billing, and enable the Cloud Text-to-Speech API.
  2. Install the Google Cloud CLI. Run gcloud init and sign in with an account allowed to use that project.
  3. Open PowerShell in the folder where you want to save the MP3. In the example below, replace YOUR_PROJECT_ID and the announcement text. The sample requests German speech (de-DE).
  4. Run the example. It requests MP3 audio and saves the decoded response as station-announcement.mp3 in the current folder. It does not print your access token.
Create-GoogleAnnouncement.ps1
$ttsProject = "YOUR_PROJECT_ID"
$ttsToken = (gcloud auth print-access-token).Trim()
$ttsRequest = @{
    input = @{ text = "Achtung, Einsatz fuer die Feuerwehr. Bitte zur Fahrzeughalle." }
    voice = @{ languageCode = "de-DE" }
    audioConfig = @{ audioEncoding = "MP3" }
} | ConvertTo-Json -Depth 4

$ttsResponse = Invoke-RestMethod `
    -Method Post `
    -Uri "https://texttospeech.googleapis.com/v1/text:synthesize" `
    -Headers @{ Authorization = "Bearer $ttsToken"; "x-goog-user-project" = $ttsProject } `
    -ContentType "application/json; charset=utf-8" `
    -Body ([System.Text.Encoding]::UTF8.GetBytes($ttsRequest))

[System.IO.File]::WriteAllBytes(
    (Join-Path (Get-Location).Path "station-announcement.mp3"),
    [System.Convert]::FromBase64String($ttsResponse.audioContent)
)
  1. Play the saved file locally. For a specific voice, use Google's current voice catalog and add its exact name to the request's voice object.
  2. Continue with Upload and play the MP3.

This is a one-time audio export. For changing text entered in-game, follow Automatic TTS. Keep Google authentication on the backend, following its authentication guide.

ElevenLabs

For fixed announcements, ElevenLabs offers a browser workflow without writing an API integration.

  1. Sign in to ElevenLabs and open Text to Speech.
  2. Choose a voice suited to your language. For German voices, use the language filter in the Voice Library. The speech language follows your text; a separate language selector is not required for this workflow.
  3. Enter the complete announcement and choose Generate speech.
  4. Listen to the result. Adjust the wording or voice and generate it again if needed.
  5. Use the download button for the generated result, or open it in History, and download MP3 (128 kbps). See ElevenLabs' download instructions.
  6. Continue with Upload and play the MP3.

For automated generation, the ElevenLabs API uses a POST request with a voice ID and an xi-api-key header. This needs a backend integration; the API address cannot be pasted into TTS URL Template as a ready playback link.

VoiceRSS

VoiceRSS can return MP3 audio from an API request. Its API key must stay out of player-visible URLs and Jobs Base configuration.

  1. Create a VoiceRSS account and obtain your API key.
  2. Open PowerShell 7 in the folder where you want to save the MP3. The example uses Read-Host -MaskInput, which hides the key while you enter it.
  3. Run the example below and enter your key at the prompt. Change src to your announcement. hl = "de-de" selects German and c = "MP3" selects MP3 output.
Create-VoiceRSSAnnouncement.ps1
$ttsKey = Read-Host "VoiceRSS API key" -MaskInput
$ttsRequest = @{
    key = $ttsKey
    hl = "de-de"
    src = "Achtung, Einsatz fuer die Feuerwehr. Bitte zur Fahrzeughalle."
    c = "MP3"
    f = "44khz_16bit_mono"
    b64 = "false"
}
Invoke-WebRequest `
    -Method Post `
    -Uri "https://api.voicerss.org/" `
    -Body $ttsRequest `
    -OutFile "station-announcement.mp3"
  1. Play station-announcement.mp3. If VoiceRSS returned an error message instead of audio, correct the key, quota or request settings before uploading it. See the VoiceRSS API reference.
  2. Continue with Upload and play the MP3.

VoiceRSS also accepts GET, but putting its API URL with your private key into TTS URL Template would expose that key to players. For automatic speech, use a backend as described below.

3. Upload and play the MP3

  1. Upload the finished MP3 to a web server that your players can reach. For example, https://audio.example.org/announcements/station-announcement.mp3. Replace the example domain with your real host.
  2. Open the direct link in a browser and confirm that the MP3 plays without a login or a file-sharing preview page. Keep the link stable and use HTTPS.
  3. In Jobs Base's Announcement settings, leave TTS URL Template empty. Add the exact hostname to Allowed Audio Hosts. For the example, enter only audio.example.org.
  4. Do not include https://, a port, a path or a wildcard in the host entry. Subdomains need their own entries: allowing example.org does not also allow audio.example.org.
  5. Save. Open Tablet → Dispatch → Open Dispatcher, start your permitted shift, and go to Communication → Station announcement.
  6. Select the station, leave Announcement text empty, paste the full link into Approved audio URL, and select Send announcement.
  7. Have a player stand near that station to hear the result. Wait at least 10 seconds before sending another announcement with the default cooldown.

For file configuration, the equivalent section is shown below. Update only the existing announcement section inside Config.Dispatch; keep the other Dispatch settings.

sky_jobs_base/config/config.lua — inside Config.Dispatch
announcement = {
    enabled = true,
    resource = "xsound",
    defaultRadius = 65.0,
    ttsUrlTemplate = "",
    allowedAudioHosts = { "audio.example.org" }
},

4. Automatic TTS: optional developer integration

Use this workflow when dispatchers should type new text in-game and have it spoken automatically. Jobs Base does not include a Google Cloud, ElevenLabs or VoiceRSS synthesis backend. Setting up a provider account alone does not create a compatible TTS URL.

What the URL must do

  1. Provide a player-accessible GET endpoint that returns playable audio directly, such as raw MP3 with Content-Type: audio/mpeg. A JSON response, normal website or login page is not audio.
  2. Place {text} in that endpoint's URL where it expects the announcement text. Jobs Base URL-encodes the text before inserting it; keep the placeholder exactly as shown.
  3. Store any provider credentials exclusively on your backend. Google REST needs its response's audioContent decoded; ElevenLabs can return MP3 bytes; VoiceRSS should request c=MP3.
  4. Cache by text, voice and audio settings, and reuse the same result for concurrent requests. Multiple players can load one announcement URL, so one listener must not cause a new paid synthesis of the same announcement.
  5. Protect the operation that creates new provider audio. Hiding a provider key behind a publicly accessible, unrestricted synthesis endpoint is not sufficient. A fixed token in the playback URL is visible to players too. Your developer may need an authenticated server-side synthesis step and a separate playback endpoint for already approved audio; that step is additional integration work beyond the existing URL-template setting.

The backend's language and deployment depend on your hosting, for example PHP webspace or a Node.js service on your own server. Follow the provider's authentication and API documentation. The requirements above describe the integration contract, not a bundled proxy or a provider URL that is ready to paste.

Connect an existing compatible endpoint

  1. First confirm that your endpoint produces audio for a short test sentence when opened in a browser, without requiring player logins or private request headers.
  2. Set TTS URL Template to its address, for example https://tts.example.org/speech.mp3?text={text}. This is an illustrative address; replace it with the endpoint you have actually deployed.
  3. Allowed Audio Hosts can stay empty when you use only the configured TTS template. This list controls manually entered audio URLs, not the configured template.
  4. Save. In Station announcement, select the station and enter a short Announcement text. Leave Approved audio URL empty and send the announcement.
  5. Check playback near the station. With both a TTS template and text present, the generated TTS URL takes precedence over a manually entered audio URL.

Troubleshooting

What you seeWhat to check
No station-announcement panelEnable announcements, start the configured xSound resource, and configure a TTS template or at least one allowed audio host. Check the shift's announcement capability.
The station selector is emptyAdd a center station for a covered job. Supply coordinates or the exact name of an existing POI for that job.
Permission denied or disabled controlsCheck duty, center access, selected shift roles and effective permission grants. The default announcement role is Situation control; default permission IDs are 21 and 23.
Audio URL rejectedEnter the full direct URL in the announcement form, and only its exact hostname in Allowed Audio Hosts.
Google/ElevenLabs API URL does not playThese APIs need requests that the playback template does not make. Export and host an MP3, or implement the backend described above.
Accepted, but no soundTest the direct audio URL, xSound, the listener's sound settings, distance to the configured station and routing bucket. An accepted send does not confirm media playback on every client.
The MP3 contains an error messageFix the provider authentication, quota or input error, then generate a real audio file again. Renaming an error response to .mp3 does not convert it.
Editing config.lua changes nothingSaved /jobconfig settings take precedence while the ingame configurator is enabled. Edit the effective saved settings.

For department-wide written notices, see Business and Announcements.