PHPackages                             robtesch/watson\_tts - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. robtesch/watson\_tts

AbandonedArchivedLibrary

robtesch/watson\_tts
====================

A Laravel package for making use of IBM's Watson Text-To-Speech Service

v0.0.2(7y ago)0161[2 PRs](https://github.com/robtesch/watson-tts/pulls)MITPHPPHP ^7.3

Since Jan 17Pushed 3y agoCompare

[ Source](https://github.com/robtesch/watson-tts)[ Packagist](https://packagist.org/packages/robtesch/watson_tts)[ Docs](https://github.com/robtesch/watson-tts)[ RSS](/packages/robtesch-watson-tts/feed)WikiDiscussions master Synced today

READMEChangelogDependencies (7)Versions (6)Used By (0)

watson-tts
==========

[](#watson-tts)

A laravel package designed to help you make use of IBM's Watson Text-To-Speech (TTS) service.

Installation
------------

[](#installation)

1. You can install this package within a new or existing laravel project using composer:

```
composer require robtesch/watson_tts
```

3. If you're running Laravel &gt;= 5.5, package discovery will configure the service provider and `Watsontts` alias out of the box.

    Otherwise, for Laravel &lt;= 5.4, edit your `config/app.php` file and:

    - add the following to the `providers` array: ```
        Robtesch\Watsontts\WatsonServiceProvider::class,
        ```
    - add the following to the `aliases` array: ```
        'Watsontts' => Robtesch\Watsontts\Facades\Watsontts::class,
        ```
4. Run the command below to publish the package config file [config/watson-tts.php](src/config/watson-tts.php):

```
php artisan vendor:publish --provider="Robtesch\Watsontts\WatsonServiceProvider"
```

Configuration
-------------

[](#configuration)

If you are planning to use a single account, you might want to add the following to your `.env` file.

```
WATSON_ENDPOINT='https://stream.watsonplatform.net/text-to-speech/api'
WATSON_API_VERSION=v1
WATSON_USERNAME=someusername
WATSON_PASSWORD=somepassword
WATSON_FILESYSTEM_DISK=local

```

Usage
-----

[](#usage)

#### Basic usage example

[](#basic-usage-example)

This is a basic example, which will echo out all Mails within all imap folders and will move every message into INBOX.read. Please be aware that this should not ben tested in real live but it gives an impression on how things work.

```
use Robtesch\Watsontts\Watsontts;

$watsonTts = new Watsontts();

$text = 'Watson Text-To-Speech Service allows me to turn text into audio clips.';
$voice = 'en-US_LisaVoice';

//You can optionally include or exclude the file extension in the path.
$savePath = storage_path('app/path/to/save.mp3');

//If you provide a file extension, you do not need to specify the "accept" param.
$accept = 'audio/mp3';

$synthesis = $watsonTts->synthesizeAudio($text, $voice, $savePath, $accept);

//Will return a Laravel file download response.
return $synthesis->download();
```

Alternatively, if you want to customise the credentials used to connect to watson, you can instantiate a client to pass to the Watson Service.

Either pass a config array to the Client:

```
use Robtesch\Watsontts\Watsontts;
use Robtesch\Watsontts\Client;

//Config values will be used for keys not present in the config array.
$config = [
    'endpoint' => 'someotherendpoint.com',
    'api_version' => 'someotherversion',
    'username' => 'username',
    'password' => 'password',
];

$client = new Client($config);

$watsonTts = new Watsontts($client);

```

Or set the values directly on the client:

```
use Robtesch\Watsontts\Watsontts;
use Robtesch\Watsontts\Client;

$client = new Client();

$client->setEndpoint('someotherendpoint.com');
$client->setApiVersion('someotherversion');
$client->setUsername('username');
$client->setPassword('password');

$watsonTts = new Watsontts($client);

```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity49

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2636d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/1fd30161494814368e574d511856554007d880cc0380287a08ca014b21cd10f5?d=identicon)[robtesch](/maintainers/robtesch)

---

Tags

phptext-to-speechibmttswatson

### Embed Badge

![Health badge](/badges/robtesch-watson-tts/health.svg)

```
[![Health](https://phpackages.com/badges/robtesch-watson-tts/health.svg)](https://phpackages.com/packages/robtesch-watson-tts)
```

###  Alternatives

[larastan/larastan

Larastan - Discover bugs in your code without running it. A phpstan/phpstan extension for Laravel

6.4k43.5M5.2k](/packages/larastan-larastan)[roots/acorn

Framework for Roots WordPress projects built with Laravel components.

9682.1M97](/packages/roots-acorn)[laravel/vapor-cli

The Laravel Vapor CLI

31310.7M8](/packages/laravel-vapor-cli)[laravel-zero/framework

The Laravel Zero Framework.

3371.4M369](/packages/laravel-zero-framework)[josiasmontag/laravel-recaptchav3

Recaptcha V3 for Laravel package

2641.6M2](/packages/josiasmontag-laravel-recaptchav3)[aedart/athenaeum

Athenaeum is a mono repository; a collection of various PHP packages

255.2k](/packages/aedart-athenaeum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
