Environment as a service for Terraform.
## Env0 MCP Server: Environment as a Service The **Env0 MCP Server** integrates the self-service infrastructure platform into Google Antigravity, enabling developers to manage Terraform environments with cost tracking, policy enforcement, and approval workflows. ### Why Env0 MCP? - **Self-service** - Developer-friendly environment management - **Cost tracking** - Real-time infrastructure cost visibility - **Policy engine** - OPA-based policy enforcement - **Approval workflows** - Configurable approval gates - **Templates** - Reusable environment templates ### Key Features #### 1. Environment Management ```python # Create environment env = await mcp.call("env0", "create_environment", { "name": "staging-app", "project_id": "proj_xxx", "template_id": "tmpl_xxx", "configuration": [ {"name": "region", "value": "us-east-1"}, {"name": "instance_type", "value": "t3.medium"} ] }) # Deploy environment deployment = await mcp.call("env0", "deploy", { "environment_id": env["id"] }) ``` #### 2. Deployment Tracking ```python # Get deployment status status = await mcp.call("env0", "get_deployment", { "deployment_id": deployment["id"] }) print(f"Status: {status[\"status\"]}") # Get deployment logs logs = await mcp.call("env0", "get_deployment_logs", { "deployment_id": deployment["id"] }) ``` #### 3. Cost Analysis ```python # Get environment costs costs = await mcp.call("env0", "get_costs", { "environment_id": env["id"] }) print(f"Monthly cost: ${costs[\"monthly_cost\"]}") # Get project cost breakdown breakdown = await mcp.call("env0", "get_cost_breakdown", { "project_id": "proj_xxx" }) ``` #### 4. Template Management ```python # List templates templates = await mcp.call("env0", "list_templates", { "project_id": "proj_xxx" }) # Create template template = await mcp.call("env0", "create_template", { "name": "Production VPC", "repository": "org/terraform-modules", "path": "modules/vpc" }) ``` ### Configuration ```json { "mcpServers": { "env0": { "command": "npx", "args": ["-y", "@anthropic/mcp-env0"], "env": { "ENV0_API_KEY": "your-api-key", "ENV0_API_SECRET": "your-secret" } } } } ``` ### Use Cases **Self-Service Infra**: Let developers provision environments. **Cost Management**: Track infrastructure costs. **Compliance**: Enforce policies on deployments. **Environment Templates**: Standardized infrastructure. The Env0 MCP Server enables self-service infrastructure.
{
"mcpServers": {
"env0": {}
}
}