Code Execution
The AgentiCode MCP server provides sandboxed code execution in user-isolated workspaces.
Authentication: User session with workspace isolation
Tools
execute_code
Execute code in multiple languages:
Input:
code: string - Code to execute
language: string - Programming language
user_id: string - User identifier
filename?: string - Optional filename
timeout_seconds?: number - Timeout (default: 30)
Output:
stdout: string - Standard output
stderr: string - Standard error
exitCode: number - Exit code
filename: string - Executed file
filepath: string - Full path
Supported Languages:
- python
- javascript
- typescript
- go
- bash / shell
- sql
- rustrun_shell_command
Execute shell commands:
write_file
Write file to workspace:
read_file
Read file from workspace:
list_files
List workspace files:
get_session_info
Get user session details:
stop_session
Stop user session:
Architecture
Workspace Isolation
Each user gets an isolated workspace:
Path:
/workspaces/{userId}Files persist across sessions
No access to other users' workspaces
Resource limits enforced
Supported Languages
Python
JavaScript
TypeScript
Go
Bash/Shell
SQL
Rust
Timeouts
Default: 30 seconds
Maximum: 300 seconds (5 minutes)
Long-running tasks should use background execution
Security
Sandboxed execution: Isolated from host system
Resource limits: CPU, memory, disk quotas
Network isolation: Limited network access
No root access: Runs as unprivileged user
File system isolation: Per-user workspaces only
Last updated