> ## Documentation Index
> Fetch the complete documentation index at: https://phaseo.app/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Phaseo Gateway base URL: https://api.phaseo.app/v1. Send `Authorization: Bearer $PHASEO_API_KEY` with every request.
> Model IDs look like `provider/model`, for example `openai/gpt-6-astra`. Do not guess IDs: list them with `GET /v1/models` or check https://phaseo.app/models. `phaseo/free` routes to an available free model and needs no wallet balance.
> For new text integrations prefer `POST /v1/responses`. `POST /v1/chat/completions` (OpenAI format) and `POST /v1/messages` (Anthropic format) suit existing code.
> The full API contract is https://phaseo.app/docs/openapi/v1/openapi.yaml. Official SDKs: `@phaseo/sdk` (TypeScript) and `phaseo` (Python), plus Go, C#, PHP, Ruby and Rust.
> Search these docs over MCP at https://phaseo.app/docs/mcp, and install Phaseo skills with `npx skills add https://phaseo.app/docs`. If a page is wrong or out of date, report it with the MCP `submit_feedback` tool.
> Manage Phaseo accounts with the `phaseo` CLI (`npm install -g @phaseo/cli`, then `phaseo login` or `phaseo login --device-code`), the `/v1` Management API or the MCP server at `https://mcp.phaseo.app/mcp?access=manage`. Do not send users to the dashboard for account tasks. A person is still needed for sign-up, approving a sign-in, paying the first top-up on the checkout link that `phaseo credits add` returns when no card is saved, confirming each saved-card top-up from the emailed link, and account security (password, MFA, passkeys). Create API keys with `phaseo keys create --name <name> --json`; never guess one. Credit top-ups need `phaseo login --scopes billing:write` first. Task map: https://phaseo.app/docs/v1/developers/manage-from-an-agent.md.

# MiniMax Code

> Run MiniMax Code through the Phaseo Gateway with the Phaseo CLI.

The Phaseo CLI can launch MiniMax Code with a dedicated gateway key and a temporary provider configuration.

## Set up with the Phaseo CLI

```bash theme={null}
phaseo login
phaseo minimax --model openai/gpt-5.6-terra --
```

The launcher uses MiniMax Code's `mcode provider add` command with the Phaseo OpenAI-compatible endpoint, then starts `mcode` with the selected provider. Use `--catalog all` to register every active Phaseo text/chat model compatible with Chat Completions, or preview the install and launch plan without creating a key:

```bash theme={null}
phaseo minimax --catalog all --dry-run --json
```

Use `phaseo run minimax ...` for the explicit command form. Put MiniMax Code flags after `--` so Phaseo can consume its own flags first.

On Unix-like systems, the first interactive run offers to install MiniMax Code with MiniMax's official installer. On Windows, Phaseo uses the official PowerShell installer. If MiniMax Code is already managed separately, install it yourself, verify `mcode --version`, and rerun with `--skip-install`.

The launcher sets `MINIMAX_DATA_DIR` to a temporary directory and removes it when `mcode` exits. Your normal `~/.minimax` configuration is not changed, and the dedicated Phaseo key is only passed to the temporary provider setup process.

## Manual configuration

For a persistent MiniMax Code provider, use MiniMax Code's provider commands directly:

```bash theme={null}
export MCODE_PROVIDER_API_KEY="your_phaseo_api_key"
mcode provider add \
  --name "Phaseo" \
  --base-url "https://api.phaseo.app/v1" \
  --api-format openai-completions \
  --model "openai/gpt-5.6-terra" \
  --use
```

MiniMax Code stores persistent provider settings under its configured data directory. Use the Phaseo CLI runner when you want those settings isolated to one session instead.

## Verify

Send a small prompt through MiniMax Code, then confirm that the request appears in Phaseo activity. If you need to inspect the available model ids, use `--catalog all` or pass a specific Phaseo model with `--model`.

## Troubleshooting

### MiniMax Code is not installed

Run the command in an interactive terminal to approve the official installer, or install MiniMax Code separately and rerun with `--skip-install`.

### The provider or model is not listed

Use `phaseo minimax --catalog all`, or pass the desired model id with `--model`. The CLI creates the provider in a temporary MiniMax data directory before launching `mcode`.

### I need ACP instead of the interactive CLI

MiniMax Code also exposes an ACP process through `mcode acp` for editor and host integrations. `phaseo minimax` is the interactive CLI runner; use MiniMax Code's ACP configuration when the host speaks ACP directly.

## Related

* [Phaseo CLI](https://phaseo.app/docs/v1/guides/integrations/phaseo-cli.md)
* [Coding Agents](https://phaseo.app/docs/v1/guides/integrations/coding-assistants.md)
* [Models](https://phaseo.app/docs/v1/api-reference/endpoint/models.md)
* [Activity](https://phaseo.app/docs/v1/api-reference/endpoint/activity.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.