dify/api/extensions/storage
Yansong Zhang 0c7e7e0c4e feat(api): port Sandbox + VirtualEnvironment + Skill system from feat/support-agent-sandbox (Phase 5-6)
Port the complete infrastructure for agent sandbox execution and skill system:

Sandbox & Virtual Environment (core/sandbox/, core/virtual_environment/):
- Sandbox entity with lifecycle management (ready/failed/cancelled states)
- SandboxBuilder with fluent API for configuring providers
- 5 VM providers: Local, SSH, Docker, E2B, AWS CodeInterpreter
- VirtualEnvironment base with command execution, file transfer, transport layers
- Channel transport: pipe, queue, socket implementations
- Bash session management and DifyCli binary integration
- Storage: archive storage, file storage, noop storage, presign storage
- Initializers: DifyCli, AppAssets, DraftAppAssets, Skills
- Inspector: file browser, archive/runtime source, script utils
- Security: encryption utils, debug helpers

Skill & App Assets (core/skill/, core/app_assets/, core/app_bundle/):
- Skill entity and manager
- App asset accessor, builder pipeline (file, skill builders)
- App bundle source zip extractor
- Storage and converter utilities

API Endpoints:
- CLI API blueprint (controllers/cli_api/) for sandbox callback
- Sandbox provider management (workspace/sandbox_providers)
- Sandbox file browser (console/sandbox_files)
- App asset management (console/app/app_asset)
- Skill management (console/app/skills)
- Storage file endpoints (controllers/files/storage_files)

Services:
- Sandbox service, provider service, file service
- App asset service, app bundle service

Config:
- CliApiConfig, CreatorsPlatformConfig, CollaborationConfig
- FILES_API_URL for sandbox file access

Note: Controller route registration temporarily commented out (marked TODO)
pending resolution of deep dependency chains (socketio, workflow_comment,
command node, etc.). Core sandbox modules are fully ported and syntax-validated.
110 files changed, 10,549 insertions.

Made-with: Cursor
2026-04-08 17:39:02 +08:00
..
clickzetta_volume refactor(api): type storage statistics with StorageStatisticsDict TypedDict (#34609) 2026-04-07 00:59:32 +00:00
aliyun_oss_storage.py feat: Add OSS-specific parameters for HW and ALI private deployment (#29705) 2025-12-22 21:59:32 +08:00
aws_s3_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
azure_blob_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
baidu_obs_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
base_storage.py fix: add type annotations to BaseStorage.exists and BaseStorage.download (#32652) 2026-02-27 07:35:30 +09:00
cached_presign_storage.py feat(api): port Sandbox + VirtualEnvironment + Skill system from feat/support-agent-sandbox (Phase 5-6) 2026-04-08 17:39:02 +08:00
file_presign_storage.py feat(api): port Sandbox + VirtualEnvironment + Skill system from feat/support-agent-sandbox (Phase 5-6) 2026-04-08 17:39:02 +08:00
google_cloud_storage.py refactor(api): replace json.loads with Pydantic validation in controllers and infra layers (#34277) 2026-04-01 05:41:44 +00:00
huawei_obs_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
opendal_storage.py fix: pass default root to OpenDAL Operator for fs scheme (#33678) 2026-03-19 15:30:13 +08:00
oracle_oci_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
storage_type.py Fix token expiry miscalculation (#24639) 2025-08-27 18:19:58 +08:00
storage_wrapper.py feat(api): port Sandbox + VirtualEnvironment + Skill system from feat/support-agent-sandbox (Phase 5-6) 2026-04-08 17:39:02 +08:00
supabase_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
tencent_cos_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00
volcengine_tos_storage.py ci: try from main repo (#32620) 2026-02-26 16:30:10 +09:00