Guía de inicio
Primeros pasos con manage-env
Más formas de usar esta guía
Instala manage-env, conéctalo a tu herramienta de programación con IA y configura un repositorio sin poner secretos en el chat.
En esta página
Empezar con IA
Copia un solo prompt en tu herramienta de IA y completa en tu terminal los pocos pasos de confianza que requieren tu intervención.
# Set up manage-env (menv) in this repository
manage-env is a zero-knowledge secrets manager for env vars. Secret VALUES must
never enter your context, the chat, or any log - and you never need them to.
Follow these steps in order.
## 1. Install the CLI yourself
Run `menv --version`. If it is missing, install the public macOS/Linux CLI in
your terminal:
`curl -fsSL https://manage-env.com/install | sh`
Then run `export PATH="$HOME/.local/bin:$PATH"` in your current shell and
verify with `menv --version`. Do not ask the human to install the CLI or change
PATH for you. If your client cannot execute the command or requires approval,
request that approval and report the exact blocker instead. Do not send them to
the private GitHub repository.
## 2. Connect the repo yourself
Run `menv connect` from the repository root. It registers the local menv MCP
server for your client and writes the full agent guide into AGENTS.md. It only
touches repo-local files and handles no secret value. Afterwards, reload MCP
servers (or ask the human to restart their AI tool) so the menv tools load.
## 3. Secure user handoff: sign in
Only account authentication requires the human's direct terminal input. Ask
them to run `menv signup` (or `menv login` if they have an account) and enter
the email code, password, and one-time recovery key outside the chat. Do not
ask for, accept, or relay any of those values. Wait until they confirm sign-in.
## 4. Agent steps (menv MCP tools)
- Start with `detect_required_keys` (scans .env.example; works before init).
- If this directory is not bound to a project, call `init_project` - and if
the `org/project` address is not already clear, ask the human for it
instead of inventing one.
- Call `setup_project` to mint random secrets, keypairs, and config defaults
in one version. Treat `needs_user` as the only list of decisions to bring
back to the human.
- Externally-issued keys (STRIPE_*, DATABASE_URL, cloud creds):
`request_value_from_user` - the human pastes the value at their own
terminal. NEVER ask for a secret value in chat.
- Run anything that needs secrets with the `run_with_secrets` MCP tool. If it
fails, it returns a masked tail of the output (injected values shown as
`[menv:masked:KEY]`) so you can debug without the secrets; if
`output_suppressed` is set, a value was too short to mask and the output was
dropped - ask the human to run it in their terminal.
- When a result reports `stale_sync_targets`, re-sync each one with
`sync_to_target`.
## Hard rules
- Never `cat .env`, `printenv`, or log `process.env` - reading a value
defeats the whole point and is treated as an incident.
- Use the `run_with_secrets` MCP tool, not the `menv run` CLI, to run things.
`menv run` is the human's terminal path; its output isn't masked when a human
runs it interactively, and `menv run --raw-output` disables masking entirely
and requires a human at the terminal.
- There is no tool that returns a secret value, by design. Do not try to
reconstruct values by any other route.
- Do not run `menv run --yes` or `menv run --raw-output` on the human's
behalf; those confirmation prompts exist for them, not you.
Full tool discipline: AGENTS.md after `menv connect`, or
https://manage-env.com/llms.txt
Configuración única en terminal
Estos pasos cambian tu equipo o verifican tu identidad, por eso los ejecutas tú. No pegues contraseñas, códigos ni secretos en el chat.
-
Instala la CLI pública
Funciona en macOS y Linux y verifica el binario descargado.
curl -fsSL https://manage-env.com/install | sh -
Crea una cuenta o inicia sesión
Usa signup para una cuenta nueva o login para una existente. Introduce el código y la contraseña solo en tu terminal.
menv signup # o: menv login -
Conecta desde la raíz del repositorio
Registra el servidor MCP local de menv en Claude Code y Cursor y añade las reglas de seguridad a AGENTS.md.
menv connectLa instalación en un clic registra el servidor MCP de menv en tu propia configuración de Cursor o VS Code. Ejecuta también menv connect en el repositorio: crea el .mcp.json compartido y la guía de seguridad en AGENTS.md.
-
Reinicia tu herramienta de IA
Reiníciala por completo para cargar el servidor MCP y aprueba menv si te lo pide.
La IA continúa desde aquí
Después de reiniciar, pega el prompt superior en una conversación nueva. La IA informa estados y nombres de claves, no valores.
detect_required_keys Detecta las variables necesarias
Lee .env.example y separa lo que puede generar de lo que necesita tu decisión.
init_project · setup_project Crea el proyecto y valores seguros
Vincula el repositorio, genera secretos y pares de claves y completa valores no secretos.
request_value_from_user Solo pide valores emitidos por proveedores
Las claves de Stripe y URLs de bases de datos se introducen en una terminal local que la IA no puede leer.
run_with_secrets · sync_to_target Ejecuta y sincroniza destinos aprobados
Usa los valores sin devolverlos y muestra solo resultado, duración, destino y nombres de claves.
¿Dónde van los secretos?
La IA coordina el trabajo; las rutas locales de confianza manejan los valores.
Chat y resultados de herramientas
Reciben estado, nombres de claves y próximos pasos. No pegues secretos en el chat.
Tu terminal y procesos locales
Introduces localmente los valores externos. Se descifran e inyectan solo cuando un proceso aprobado los necesita.
Servidor de manage-env
Guarda datos cifrados y metadatos sin valores. No recibe los valores en texto plano necesarios para abrir tu caja fuerte.
Solución de problemas
No se encuentra el comando menv
Añade $HOME/.local/bin a PATH, abre una terminal nueva y ejecuta menv --version otra vez.
La IA no ve las herramientas de menv
Ejecuta menv connect en la raíz, reinicia la herramienta de IA y aprueba el servidor MCP de menv si aparece.
La IA dice que debes introducir un valor
Pégalo en el aviso de la terminal local. Nunca respondas con el valor en el chat.
¿Listo para conectar tu primer repositorio?
Las cuentas individuales son gratis. Crea una cuenta y vuelve aquí para copiar el prompt.
Crear una cuenta gratis