langchain-sandrpod
SandrPod sandbox integration for Deep Agents.
Installation
pip install langchain-sandrpod
Quick Start
from langchain_sandrpod import SandrPodClient
from deepagents import create_deep_agent
from deepagents.middleware import FilesystemMiddleware
client = SandrPodClient(api_url="http://localhost:8080")
with client.sandbox("my-sandbox") as sb:
# Run a command directly
result = sb.execute("python3 -c 'print(42)'")
print(result.output) # 42
# Or plug the sandbox into a deepagents agent
agent = create_deep_agent(
middleware=[FilesystemMiddleware(backend=sb)]
)
result = agent.invoke({"messages": [{"role": "user", "content": "List the files under /workspace"}]})
Sandbox surface
| Capability | Methods |
|---|---|
| One-shot execution | execute(cmd) |
| Files | ls / read / write / edit / delete / grep / glob / upload_files / download_files (write overwrites existing files; delete natively calls /files/delete — both match the deepagents backend contract) |
| Stateful interpreter (variables persist across calls) | run_code(code, context_id=…) + create/list/restart/remove_code_context |
| Directory watch | watch_dir(path) / get_new_events(watcher_id) |
| Resource usage | metrics() |
| MCP config & calls | mcp_ls / mcp_add / mcp_rm / mcp_tools / mcp_manifest / mcp_url |
See examples/ — including 04_personal_mcp.py, which exposes the
personal MCP tools on an employee machine to a remote agent via the sandbox's
/mcp endpoint.
Environment Variables
| Variable | Description | Default |
|---|---|---|
SANDRPOD_API_URL |
API Server address | http://localhost:8080 |
SANDRPOD_API_TOKEN |
Platform-layer Bearer token | (empty) |
SANDRPOD_MCP_TOKEN |
Resource-layer mcp_token (shared secret of the in-sandbox bridge, optional) |
(empty) |
Metadata
Release files for langchain-sandrpod 0.2.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| langchain_sandrpod-0.2.7.tar.gz | 23.8 kB | Without provenance | Details for langchain_sandrpod-0.2.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| langchain_sandrpod-0.2.7-py3-none-any.whl | Python 3 | none | any | Details for langchain_sandrpod-0.2.7-py3-none-any.whl |
Total release size: 41.7 kB
Release files / langchain_sandrpod-0.2.7.tar.gz
| Download URL | langchain_sandrpod-0.2.7.tar.gz |
|---|---|
| Size | 23.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cba457eec925b75c0a04723bff87abd7347c04447bd6826795f9edd7c866b630
|
|
BLAKE2b-256 checksum How to use checksums |
12414d43aa3a7f5d0c3184faea5914390cc9982f15b65f65ad8ce619b825a275
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Release files / langchain_sandrpod-0.2.7-py3-none-any.whl
| Download URL | langchain_sandrpod-0.2.7-py3-none-any.whl |
|---|---|
| Size | 17.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f1805d30c9a122ba13756730dc010f309ec3e0fbe65a992f8e5fa5f76dc0964a
|
|
BLAKE2b-256 checksum How to use checksums |
a14cbb20c60b2343f5368c6603a310effc2b19f646a7215df574b59a57f240e5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.14
|
Security for langchain-sandrpod 0.2.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.