Terminal-first software engineering has entered an agentic era, yet backend engineers routinely run into an infuriating bottleneck: terminal AI agents cannot natively query local databases, inspect schema migrations, or trigger internal security linters. Developers are forced to break flow, copy SQL schemas or API schemas into browser windows or separate GUI tools, and paste generated code back into their terminal sessions.
At 365Finds, our institutional stance is unambiguous: GUI-bound MCP wrappers (such as desktop IDE panels) are fine for front-end tinkering, but for backend infrastructure, system architecture, and command-line diagnostics, the terminal is home. Mistral Vibe provides native support for the open Model Context Protocol (MCP), enabling command-line agents to directly query local database schemas, run deterministic security scanners, and integrate private developer APIs without leaving the shell.
This guide provides engineering teams with a production-ready blueprint for configuring MCP servers in Mistral Vibe—covering CLI management, TOML configuration orchestration, transport protocols (stdio and streamable-http), credential isolation, runtime inspection, and security governance.
Architectural Mechanics: How Mistral Vibe Handles MCP
Mistral Vibe connects to external developer infrastructure by treating MCP tools identically to built-in tools. When properly registered, an MCP server’s methods become accessible to Mistral Vibe’s underlying model (such as Devstral or Mistral Large) as callable functions.
+-------------------------------------------------------------------------+
| Mistral Vibe CLI |
| (Interactive Chat / Programmatic Mode / Approvals: smart-approve/ask) |
+--------------------+-------------------------------+--------------------+
| |
stdio Transport (Local Subprocess) streamable-http / http
| |
+------------v------------+ +-----------v------------+
| Local Node / Python CLI | | Local Daemon / Remote |
| - Postgres MCP Server | | - Dev API Gateways |
| - Aikido Security MCP | | - Mistral Studio MCP |
+------------+------------+ +-----------+------------+
| |
+------------v------------+ +-----------v------------+
| Local PostgreSQL Engine | | Enterprise Services & |
| (Read-Only Schema/Data) | | Security Scanner APIs |
+-------------------------+ +------------------------+
Configuration Hierarchy and Scoping
Mistral Vibe resolves configurations across two distinct layers:
- User-Level (Global): Stored at
~/.vibe/config.toml(or$VIBE_HOME/config.toml). This file defines global tooling available across all terminal sessions on your machine. - Project-Level (Repository): Stored at
.vibe/config.tomlwithin the project root. This file allows teams to commit MCP declarations and tool permissions directly to the code repository, ensuring that every developer receives identical agent configurations upon checkout.
[!IMPORTANT] The Trusted Folders Guardrail: Because project-level
.vibe/directories can define executable CLI commands and modify agent permissions, Mistral Vibe enforces a "Trusted Folders" security check. Vibe will refuse to load repository configurations until the developer explicitly trusts the directory upon first launch.
Supported Transports
Mistral Vibe supports three primary transport mechanisms:
stdio: Runs a local binary or package via standard input and output (e.g., launching an npm package vianpxor a Python package viauvx). Best suited for database schema inspectors, local file parsers, and command-line security tools.streamable-http: Communicates with local HTTP daemons or remote services over HTTP with streaming response support. Essential for low-latency streaming tool outputs and complex API gateways.http: Standard HTTP request-response transport for REST-based microservices and endpoints without streaming.
Method 1: Adding MCP Servers via the Vibe CLI
For quick setups and local experimentation, Mistral Vibe includes a dedicated CLI command: vibe mcp add. This command immediately validates parameters and writes the server definition into your user-level config.toml without starting an interactive session.
1. Adding a Local Process via stdio
To add a local utility running via Python’s uvx or Node’s npx:
# Registering a local fetching tool via uvx
vibe mcp add fetch_server \
--transport stdio \
--command uvx \
--arg mcp-server-fetch
# Registering a local security scanner via npx
vibe mcp add aikido \
--transport stdio \
--command npx \
--arg -y \
--arg @aikidosec/mcp@latest
- Flags can be repeated: pass
--argfor each CLI argument and--envfor process-specific environment variables (e.g.,--env LOG_LEVEL=debug).
2. Adding a Remote or Daemon Server via streamable-http
When connecting to internal corporate developer APIs or Mistral Studio workspace tools protected by static API tokens:
vibe mcp add internal_api \
--url https://dev-api.internal.net/mcp \
--transport streamable-http \
--api-key-env INTERNAL_DEV_API_KEY
--api-key-envpoints Mistral Vibe to an environment variable containing the bearer token, avoiding storing raw credentials in disk configuration files.
3. Adding an OAuth-Enabled Server
If your team integrates with cloud services that enforce OAuth (such as Linear or Atlassian):
vibe mcp add linear --url https://mcp.linear.app/mcp
Mistral Vibe opens your local browser to execute the OAuth grant. You can append --no-login to persist the registration without immediate browser authentication, or pass --scope for specific OAuth claims.
To remove any configured server:
vibe mcp remove internal_api
Method 2: Declarative Orchestration in config.toml
For institutional engineering setups, 365Finds strongly advises managing MCP servers declaratively inside config.toml rather than issuing imperative CLI commands. Declarative configuration allows your DevOps team to version-control standard developer environments inside repository .vibe/ directories.
In Mistral Vibe, MCP servers are declared as an array of tables under [[mcp_servers]].
Full config.toml Orchestration Example
Here is an enterprise-grade configuration orchestrating a local PostgreSQL database inspector, an Aikido code security scanner, and an internal microservice API:
# ==============================================================================
# Mistral Vibe Configuration: MCP Infrastructure Orchestration
# Location: ~/.vibe/config.toml (or project root .vibe/config.toml)
# ==============================================================================
# 1. Local Database Inspector (stdio)
[[mcp_servers]]
name = "postgres"
transport = "stdio"
command = "npx"
args = [
"-y",
"@modelcontextprotocol/server-postgres",
"postgresql://vibe_readonly:SecretPass123@localhost:5432/orders_dev"
]
startup_timeout_sec = 15
tool_timeout_sec = 60
[mcp_servers.env]
NODE_ENV = "development"
# 2. Local Code Security & Secret Scanner (stdio)
[[mcp_servers]]
name = "aikido"
transport = "stdio"
command = "npx"
args = ["-y", "@aikidosec/mcp@latest"]
startup_timeout_sec = 20
tool_timeout_sec = 90
# 3. Internal Development API Gateway (streamable-http)
[[mcp_servers]]
name = "internal_gateway"
transport = "streamable-http"
url = "http://127.0.0.1:8080/mcp"
startup_timeout_sec = 10
tool_timeout_sec = 45
[mcp_servers.auth]
type = "static"
api_key_env = "INTERNAL_GATEWAY_TOKEN"
api_key_header = "Authorization"
api_key_format = "Bearer {token}"
headers = { "X-Client-Agent" = "mistral-vibe" }
# ==============================================================================
# Security & Permission Controls
# ==============================================================================
# Fast schema queries can be auto-approved, while broad queries require developer confirmation
[tools.postgres_describe_table]
permission = "always"
[tools.postgres_query]
permission = "ask"
# Security scanning runs automatically
[tools.aikido_scan_repo]
permission = "always"
# Filter active tools across servers (supports globbing)
enabled_tools = [
"postgres_*",
"aikido_*",
"internal_gateway_*"
]
Essential Server Keys Reference
| Field | Type | Default | Description |
|---|---|---|---|
name | string | required | Unique alias for the server; prefixes all exposed tool names. |
transport | string | required | Transport mechanism: stdio, streamable-http, or http. |
command / args | string / list | - | Executable command and argument list for stdio servers. |
url | string | - | Base endpoint URL for HTTP and streamable-http servers. |
env | table | {} | Key-value environment variables passed to the child process. |
startup_timeout_sec | integer | 10 | Maximum seconds to wait for server initialization. |
tool_timeout_sec | integer | 60 | Maximum seconds allowed for an individual tool invocation. |
[mcp_servers.auth] | table | - | Authentication table (type = "static" or type = "oauth"). |
Practical Implementation Scenarios
Scenario 1: Connecting Terminal Agents to Local PostgreSQL
When debugging an API route or refactoring an ORM entity, terminal agents without database access frequently guess foreign key relations or generate queries against deprecated columns.
Connecting a local PostgreSQL database over MCP allows Mistral Vibe to run schema discovery (postgres_describe_table) and test SQL queries in real time.
365Finds Engineering Security Mandate
Never supply superuser credentials or read-write production connection strings to an MCP process. AI agents can hallucinate destructive DROP TABLE or TRUNCATE queries under complex prompts. Create a dedicated read-only role at the database layer:
-- Run inside PostgreSQL before configuring MCP
CREATE ROLE vibe_readonly WITH LOGIN PASSWORD 'SecretPass123';
GRANT CONNECT ON DATABASE orders_dev TO vibe_readonly;
GRANT USAGE ON SCHEMA public TO vibe_readonly;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO vibe_readonly;
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON ALL TABLES TO vibe_readonly;
Terminal Interaction Example
With the PostgreSQL MCP server configured, launch Mistral Vibe in your project root:
vibe
Inside the interactive terminal prompt, you can query directly:
> Check the current schema for the customer_orders table using MCP tools,
then write a SQL migration in src/db/migrations to add a composite index
on (customer_id, created_at).
Mistral Vibe will execute postgres_describe_table, inspect column definitions and existing indexes, and construct the precise migration file without requiring you to open pgAdmin, DBeaver, or psql.
Scenario 2: Inline Security Scanning with Aikido MCP
Automating SAST (Static Application Security Testing) and secret leak detection within the agent loop eliminates toxic security debt before commits reach pull request review.
Once the @aikidosec/mcp server is defined in config.toml, Mistral Vibe automatically discovers tools like aikido_scan_repo and aikido_check_secrets.
Triggering In-Terminal Scans
> I just refactored authentication handling in src/auth/jwt.py.
Run an Aikido security scan on this module to ensure no tokens
or hardcoded cryptographic secrets were inadvertently introduced.
The agent runs the deterministic security scanner through the local subprocess and reports verified CVEs, leaked tokens, or high-severity vulnerabilities directly in the terminal stream.
Runtime Management, Diagnostics, and Slash Commands
Mistral Vibe includes a comprehensive set of /mcp slash commands to inspect, authenticate, and troubleshoot tool servers directly inside an active session:
+--------------------+---------------------------------------------------------------+
| Slash Command | Description & Primary Action |
+--------------------+---------------------------------------------------------------+
| /mcp | Lists all configured MCP servers and active connections. |
| /mcp <server_name> | Displays the exact tool catalog and schema for that server. |
| /mcp status | Checks connection health, transport states, and auth status. |
| /mcp add <url> | Interactively adds an OAuth HTTP server to the session. |
| /mcp login <name> | Manually triggers an OAuth sign-in flow for a server. |
| /mcp logout <name> | Signs out of an OAuth server and clears OS keyring tokens. |
| /connectors | Built-in alias that points directly to /mcp. |
+--------------------+---------------------------------------------------------------+
Inspecting Tools In-Session
To confirm that your database or scanner server has connected successfully:
> /mcp postgres
Vibe returns the list of exposed tools:
postgres_query: Run a read query on the database.postgres_describe_table: Fetch schema information for a specific table.postgres_list_tables: Enumerate all tables in the connected schema.
Background Initialization Behavior
Mistral Vibe caches tool schemas from the previous session and re-initializes MCP servers in the background when the CLI opens. This architectural decision ensures developers do not endure latency delays during startup. If a server process fails to spawn or an endpoint is unreachable, Vibe prints a non-blocking diagnostic warning in the status line.
Governance, Permissions, and Agent Execution Modes
Connecting terminal agents to local operating system processes and network APIs necessitates strict permission guardrails. Mistral Vibe handles tool access through four complementary layers:
1. Per-Tool Granular Permissions
Every MCP tool follows the naming syntax {server_name}_{tool_name}. In config.toml, you can assign explicit permission rules:
permission = "always": The tool runs silently without prompting the developer.permission = "ask": Mistral Vibe pauses execution, displays the exact JSON payload and arguments the model intends to send, and waits for explicit developer keystroke confirmation (y/n).
# Read operations are automatic
[tools.postgres_describe_table]
permission = "always"
# Raw queries require explicit user confirmation
[tools.postgres_query]
permission = "ask"
2. Interaction with Agent Approval Modes
Mistral Vibe features built-in agent profiles that govern general execution behavior:
ask: Strict zero-trust mode. Prompts for approval on every single tool execution, regardless of individual tool configuration.accept-edits(Default): Auto-approves file modifications on disk, but strictly requests user approval for shell commands and sensitive tool calls.smart-approve: Uses an auxiliary classifier model ([utility_models].smart_approve) to assess risk. Safe tool calls execute immediately, while high-risk calls (such as dropping tables or accessing private keys) are intercepted and held for manual developer sign-off.auto-approve: Auto-approves all tool and shell executions. 365Finds strongly cautions against usingauto-approvewith MCP database connections unless running in an isolated Docker container or disposable VM.
3. Enterprise Administration Lockout
System administrators can enforce global governance across corporate machines. Setting enable_mcp = false in the enterprise administrative configuration completely locks down MCP:
# In administrative policy
enable_mcp = false
When set to false, the Vibe CLI will refuse to add, load, or execute any MCP servers, regardless of local user or project config.toml declarations.
Operational Anti-Patterns to Avoid
- Embedding Plaintext Secrets in
.vibe/config.toml: Never hardcode API tokens or database passwords into project configuration files that are checked into Git. Always useapi_key_env = "VAR_NAME"or environment variables referenced via the host shell. - Ignoring Child Process Timeouts: Default database queries on large tables can hang. Explicitly tune
startup_timeout_secandtool_timeout_secto prevent slow local MCP processes from freezing the interactive CLI stream. - Allowlisting Destructive Tools: Avoid setting
permission = "always"on tools capable of running arbitrary write operations or mutating remote states. Keep destructive tools onpermission = "ask". - Neglecting Trusted Folders: If your team works across open-source codebases, maintain vigilance when Mistral Vibe prompts to trust an unfamiliar repository folder containing a
.vibe/config.tomlfile.
Summary & Institutional Recommendation
Mistral Vibe’s implementation of the Model Context Protocol bridges the longstanding gap between terminal coding agents and local backend reality. By pairing declarative TOML orchestration in .vibe/config.toml with strict read-only database roles, granular ask permissions, and background process loading, engineering teams can build an automated, highly contextualized terminal development pipeline.
365Finds recommends standardizing MCP configurations inside team repository templates, pairing read-only database inspectors with automated SAST scanners like Aikido, and keeping tool permissions under tight, auditable version control.