Claude code execution
Code execution is Anthropic's server tool that gives Claude a sandboxed container to run Bash commands and Python and to create and edit files while it answers. The container has 5 GiB of memory and no internet access, so only its preinstalled libraries are there, and you can reuse it across requests for up to 30 days to keep the files Claude made. On Opper, Claude gets it on the Messages endpoint, passed through as Anthropic defines it. It runs on Anthropic's own route; Claude served from Bedrock or Vertex doesn't have it.
Add Claude code execution on Opper
Set up with agents
Paste this into your coding agent (Claude Code, Cursor, Codex, and more) and it will set up and build with Opper for you.
Key info
code_executionIn your code
curl https://api.opper.ai/v3/compat/v1/messages \-H "Authorization: Bearer $OPPER_API_KEY" \-H "Content-Type: application/json" \-d '{"model": "anthropic/claude-haiku-5-5", "max_tokens": 1024,"messages": [{"role": "user", "content": "Sum the first 50 primes and show your working."}],"tools": [{"type": "code_execution_20260521", "name": "code_execution"}]}'
Use Claude code execution with these models
Step-by-step setup for Claude code execution on each of these models through Opper.
More tools on Opper
OpenAI code interpreter
GPT models write and run Python in a sandbox, on the Responses endpoint.
code_interpreterGemini code execution
Gemini runs code to work out its answer, on generateContent.
codeExecutionClaude computer use
Claude drives a desktop through screenshots, clicks and typing in your agent loop.
computer_toolset