What is engine API mode
Engine API mode provides a VOICEVOX Engine-compatible HTTP API inside your Laravel app. Start your app withphp artisan serve --port=50513, then use endpoints like /audio_query and /synthesis directly.
Prerequisites
Set up VOICEVOX Core for PHP
Follow Installation and Configuration to prepare
voicevox-core-php and core libraries.Start Laravel engine
http://127.0.0.1:50513.
About port 50513
The official VOICEVOX engine uses port 50021 by default. Port 50513 is chosen so you can run the Laravel engine and the official engine at the same time. You are free to use any other port — just pass a different--port value, such as --port=8000.
The official engine automatically picks the next available port (50022, 50023, …) when 50021 is busy.
php artisan serve does the same when no --port is given (8001, 8002, …), but it fails to start if the specified port is already in use. Choose a fixed port that is unlikely to conflict with other services. Port 50513 is one example chosen to avoid collisions with both the official VOICEVOX engine (50021) and common Laravel ports.Generate talk audio
1. Create audio_query
2. Synthesize with synthesis
Use from Laravel client mode
Point client-mode URL to the Laravel engine API.Enable/disable and fallback
cancellable_synthesis and multi_synthesis can fall back to official engine.
If you rely on fallback, run official VOICEVOX engine at
VOICEVOX_ENGINE_FALLBACK_URL.Talk endpoint support
| Endpoint | Laravel engine | Fallback | Notes |
|---|---|---|---|
POST /audio_query | ✅ | ✅ | enable_katakana_english unsupported |
POST /accent_phrases | ✅ | ✅ | enable_katakana_english unsupported |
POST /synthesis | ✅ | ✅ | |
POST /mora_data | ✅ | ✅ | |
POST /mora_length | ✅ | ✅ | |
POST /mora_pitch | ✅ | ✅ | |
GET /speakers | ✅ | ✅ | |
GET /speaker_info | ✅ | ✅ | Requires resource install |
POST /cancellable_synthesis | ❌ | ✅ | Fallback only |
POST /multi_synthesis | ❌ | ✅ | Fallback only |
OpenAI-compatible TTS endpoint
POST /v1/audio/speech accepts the same request format as the OpenAI speech API. Changing the Base URL is all you need to connect any OpenAI-compatible tool — including Laravel AI SDK.
Parameters
| Parameter | Description |
|---|---|
input | Text to synthesize (max 4096 characters) |
voice | Style ID (integer), character alias (ずんだもん, 四国めたん, etc.), or OpenAI voice name (alloy, shimmer, etc.) |
speed | Playback speed applied as speedScale (0.25–4.0, default 1.0) |
response_format | Always returns wav. The value is ignored |
| Other parameters | Ignored |
OpenAI voice names (
alloy, shimmer, etc.) are provisional mappings. There is no authoritative definition of how each OpenAI voice should correspond to a VOICEVOX character, so these are convenience assignments for compatibility. Using VOICEVOX character aliases (ずんだもん, 四国めたん/ノーマル, etc.) is recommended.Next pages
Engine API: Song
Use
sing_frame_audio_query and frame_synthesis endpoints.Laravel AI SDK Integration
Configure VOICEVOX with
Audio facade workflows.