Every time you run Python code withDocumentation Index
Fetch the complete documentation index at: https://e2b.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
runCode() in JavaScript or run_code() method in Python, the code is executed in a headless Jupyter server inside the sandbox.
E2B automatically detects any plots created with Matplotlib and sends them back to the client as images encoded in the base64 format.
These images are directly accesible on the result items in the execution.results array.
Here’s how to retrieve a static chart from the executed Python code that contains a Matplotlib plot.
codeToRun/code_to_run will produce this following plot that we’re saving as chart.png file.
