PHPackages                             rayzenai/minimax-laravel - 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. [API Development](/categories/api)
4. /
5. rayzenai/minimax-laravel

ActiveLibrary[API Development](/categories/api)

rayzenai/minimax-laravel
========================

Laravel client for the Minimax APIs: text-to-image, text-to-speech, and chat completions.

v1.0.0(2mo ago)0344MITPHPPHP ^8.2

Since May 6Pushed 2mo agoCompare

[ Source](https://github.com/rayzenai/minimax-laravel)[ Packagist](https://packagist.org/packages/rayzenai/minimax-laravel)[ RSS](/packages/rayzenai-minimax-laravel/feed)WikiDiscussions main Synced 3w ago

READMEChangelog (1)Dependencies (6)Versions (2)Used By (0)

minimax-laravel
===============

[](#minimax-laravel)

A thin Laravel client for the [Minimax](https://www.minimax.io/) AI platform. Wraps the four Minimax surfaces we use day-to-day — **text-to-image**, **text-to-speech**, **chat completions**, and **voice management** (design, list, delete) — behind a single `Minimax` facade with sensible Laravel defaults (config, env, service container singletons, exception type).

It is deliberately small: each client is a few dozen lines, takes a `prompt`or `text`, and returns plain PHP — URLs, bytes, strings, arrays. There is no retry layer, no queue, no SDK-style fluent builder. Drop the result into a job, a Storage disk, an Inertia response, whatever.

What's in the box
-----------------

[](#whats-in-the-box)

ClientFacadeResponsibility`ImageClient``Minimax::image()`Text-to-image (`image_generation`). Transparently batches above the 4-image-per-call API cap so you can ask for 10 in one go.`TtsClient``Minimax::tts()`Text-to-speech (`t2a_v2`). Returns raw audio bytes (MP3 by default). Ships with a curated `VOICES` constant of common English voice IDs.`TextClient``Minimax::text()`Chat completions (`text/chatcompletion_v2`). `complete()` returns the assistant string; `raw()` returns the full payload for tool-calling use.`VoiceClient``Minimax::voice()`Voice **design** from a text prompt, **list** existing voices (system / cloned / generated), **delete** a custom voice. Custom-voice plan caps live in `minimax.voice_slots`.All clients raise `RayzenAI\Minimax\Exceptions\MinimaxException` on HTTP failures or non-zero `base_resp.status_code` responses.

Install
-------

[](#install)

```
composer require rayzenai/minimax-laravel
php artisan vendor:publish --tag=minimax-config
```

Env
---

[](#env)

```
MINIMAX_API_KEY=
MINIMAX_GROUP_ID=
MINIMAX_BASE_URL=https://api.minimax.io/v1

MINIMAX_IMAGE_MODEL=image-01
MINIMAX_IMAGE_ASPECT=9:16
MINIMAX_IMAGE_RESPONSE_FORMAT=url

MINIMAX_TTS_MODEL=speech-2.8-hd
MINIMAX_TTS_VOICE=English_radiant_girl

MINIMAX_TEXT_MODEL=MiniMax-M2.7

# Plan-tier custom voice cap (designed + cloned). Bump for higher tiers.
MINIMAX_VOICE_SLOTS=3
```

Usage
-----

[](#usage)

```
use RayzenAI\Minimax\Facades\Minimax;
use Illuminate\Support\Facades\Storage;

// 10 portrait images from one prompt.
$urls = Minimax::image()->generate('a cyberpunk samurai at dusk', 10, [
    'aspect_ratio' => '9:16',
]);

// Voiceover bytes — persist however you like.
$mp3 = Minimax::tts()->synthesize('Hello, world.', ['voice' => 'English_radiant_girl']);
Storage::disk('public')->put('hello.mp3', $mp3);

// Chat completion.
$copy = Minimax::text()->complete('Write a 30-second TikTok hook about coffee.');

// Design a new custom voice.
$voice = Minimax::voice()->design(
    prompt: 'A warm, deep British male narrator. Calm and reassuring.',
    previewText: 'Welcome back to the channel.',
);
// $voice = ['voice_id' => '…', 'trial_audio' => ]

// List + delete.
$voices = Minimax::voice()->list();          // ['system' => […], 'cloning' => […], 'generation' => […]]
Minimax::voice()->delete($voice['voice_id'], 'voice_generation');
```

Notes &amp; gotchas
-------------------

[](#notes--gotchas)

- **Image URLs expire** (~24h) on Minimax's side. Persist bytes if you need long-term storage — the package returns whatever `response_format` you ask for (URL or `data:` URI when `base64`).
- **Cloned voices stay invisible until first use** — they only appear in the `voice_cloning` bucket of `Minimax::voice()->list()` after you've used them in a TTS call once.
- **Custom voice cap is plan-tier**, not API. Entry plans allow 3. The package doesn't enforce this; `minimax.voice_slots` is exposed so the consuming app can guard before calling `design()`.
- **Voice IDs in `TtsClient::VOICES`** are a curated subset — the live system list from `Minimax::voice()->list('system')` is canonical.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance85

Actively maintained with recent releases

Popularity16

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

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

79d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/351e3224dcfda5f2fc1a86fb6424f60a9a060a39c938c6338a244d01912e077d?d=identicon)[kiran1991](/maintainers/kiran1991)

---

Top Contributors

[![timsinakiran](https://avatars.githubusercontent.com/u/50225225?v=4)](https://github.com/timsinakiran "timsinakiran (4 commits)")

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/rayzenai-minimax-laravel/health.svg)

```
[![Health](https://phpackages.com/badges/rayzenai-minimax-laravel/health.svg)](https://phpackages.com/packages/rayzenai-minimax-laravel)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3345.3M347](/packages/psalm-plugin-laravel)[defstudio/telegraph

A laravel facade to interact with Telegram Bots

813336.8k3](/packages/defstudio-telegraph)[laravel/mcp

Rapidly build MCP servers for your Laravel applications.

77922.3M186](/packages/laravel-mcp)[illuminate/auth

The Illuminate Auth package.

10528.2M1.3k](/packages/illuminate-auth)[api-platform/laravel

API Platform support for Laravel

58174.6k17](/packages/api-platform-laravel)[illuminate/routing

The Illuminate Routing package.

1419.2M3.2k](/packages/illuminate-routing)

PHPackages © 2026

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