tinker_cookbook.sandbox.SandboxFusionClient
class tinker_cookbook.sandbox.SandboxFusionClient(**)
Async HTTP client for SandboxFusion code execution.
run(code, files, timeout, language)
Execute code with supporting files in the sandbox.
Parameters:
- code (str) – Main code to execute (entry point)
- files (dict[str, str]) – Additional files to include {filename: content}
- timeout (float) – Execution timeout in seconds
- language (str) – Programming language (default: python)
Returns: Tuple of (success: bool, response: dict) - success is True only if status == "Success" - response contains the full API response or error details
close()
Close the HTTP session and release resources.