LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Client
  • AsyncClient
  • Run Helpers
  • Run Trees
  • Evaluation
  • Schemas
  • Utilities
  • Wrappers
  • Anonymizer
  • Testing
  • Expect API
  • Middleware
  • Pytest Plugin
  • Deployment SDK
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewClientAsyncClientRun HelpersRun TreesEvaluationSchemasUtilitiesWrappersAnonymizerTestingExpect APIMiddlewarePytest PluginDeployment SDK
Language
Theme
Pythonlangsmith_openapi_clientresourcessandboxesboxesAsyncBoxesResourcecreate_snapshot
Method●Since v0.9

create_snapshot

Copy
create_snapshot(
  self,
  path_name: str,
  *,
  body_name: str,
  checkpoint: str
View source on GitHub
|
Omit
=
omit
,
docker_image
:
str
|
Omit
=
omit
,
fs_capacity_bytes
:
int
|
Omit
=
omit
,
include_memory
:
bool
|
Omit
=
omit
,
labels
:
Dict
[
str
,
str
]
|
Omit
=
omit
,
tag
:
str
|
Omit
=
omit
,
extra_headers
:
Headers
|
None
=
None
,
extra_query
:
Query
|
None
=
None
,
extra_body
:
Body
|
None
=
None
,
timeout
:
float
|
httpx
.
Timeout
|
None
|
NotGiven
=
not_given
)
->
SnapshotResponse

Parameters

NameTypeDescription
checkpointstr | Omit
Default:omit

if omitted, creates a fresh checkpoint from the running VM

docker_imagestr | Omit
Default:omit

sandbox-local Docker image to export

fs_capacity_bytesint | Omit
Default:omit
include_memorybool | Omit
Default:omit
labelsDict[str, str] | Omit
Default:omit
tagstr | Omit
Default:omit
extra_headersHeaders | None
Default:None
extra_queryQuery | None
Default:None
extra_bodyBody | None
Default:None
timeoutfloat | httpx.Timeout | None | NotGiven
Default:not_given

Create a snapshot by capturing the current state of a sandbox or promoting an existing checkpoint.

required for Docker image export unless the sandbox has a capacity

IncludeMemory, when true, captures a full VM memory snapshot alongside the filesystem clone. Only honored when the sandbox is running AND Checkpoint is omitted (i.e. a fresh in-VM checkpoint is requested). Defaults to false to keep snapshots small unless memory restore is explicitly desired.

Labels seed the captured snapshot's labels.

mutable Docker-style tag; defaults to "latest"

Send extra headers

Add additional query parameters to the request

Add additional JSON properties to the request

Override the client-level default timeout for this request, in seconds