Skip to main content
POST
/
disk
/
{disk_id}
/
artifact
/
download_to_sandbox
Python
from acontext import AcontextClient

client = AcontextClient(api_key='sk_project_token')

# Download artifact to sandbox
result = client.disks.artifacts.download_to_sandbox(
    disk_id='disk-uuid',
    file_path='/documents/',
    filename='report.pdf',
    sandbox_id='sandbox-uuid',
    sandbox_path='/home/user/'
)
print(f"Success: {result.success}")
{
  "code": 123,
  "error": "<string>",
  "msg": "<string>",
  "data": {
    "success": true
  }
}

Authorizations

Authorization
string
header
required

Project Bearer token (e.g., "Bearer sk-ac-xxxx")

Path Parameters

disk_id
string<uuid>
required

Disk ID

Body

application/json

Download to sandbox request

file_path
string
required

File path (directory) of the artifact

filename
string
required

Filename of the artifact

sandbox_id
string
required

Target sandbox ID

sandbox_path
string
required

Destination directory in the sandbox

Response

200 - application/json

OK

code
integer
error
string
msg
string
data
object