Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
Update migration guide with hostname method info
Tomas Valenta3a0a4b1c58ae
diff --git a/apps/web/src/app/(docs)/docs/guide/beta-migration/page.mdx b/apps/web/src/app/(docs)/docs/guide/beta-migration/page.mdxindex 687a310c3..917dfc470 100644--- a/apps/web/src/app/(docs)/docs/guide/beta-migration/page.mdx+++ b/apps/web/src/app/(docs)/docs/guide/beta-migration/page.mdx@@ -22,6 +22,7 @@ The latest beta versions you should install can be found in NPM/PyPi release his- [Getting sandbox upload URL](#getting-sandbox-upload-url)- [Configuring sandbox `cwd`](#configuring-sandbox-cwd)- [Timeouts](#timeouts)+ - [Getting sandbox url](#getting-sandbox-url)- [Code Interpreter SDK changes](#code-interpreter-sdk-changes)- [Executing code](#executing-code)- [Custom template](#custom-template)@@ -415,6 +416,34 @@ There are now two types of timeouts that you can pass as parameters:This is useful for ensuring that none of the sandbox operations hang indefinitely.2. `timeout`/`timeoutMs` which is used for setting the maximum length of long-running operations like executing code, running processes, or the sandbox itself.+## Listing sandboxes+++## Getting sandbox url+The method for getting the sandbox host has changed from `sandbox.getHostname/sandbox.get_hostname` to `sandbox.getHost/sandbox.get_host`.+It now requires specifying the port.++<CodeGroup isRunnable={false}>+```js+import Sandbox from 'e2b'++// Before+// const host = await sandbox.getHostname(80)++// Now+const host = await sandbox.getHost(80)+```+```python+from e2b import Sandbox++# Before+# host = sandbox.get_hostname(80)++# Now+host = sandbox.get_host(80)+```+</CodeGroup>+## <h1>Code Interpreter SDK changes</h1>All the previously mentioned changes to the Core SDK also apply to the Code Interpreter SDK.