You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 16, 2025. It is now read-only.
Copy file name to clipboardExpand all lines: public/llms-full.txt
+93-4Lines changed: 93 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1504,6 +1504,38 @@ Organization and they may proceed by issuing a new API key and creating sandboxe
1504
1504
1505
1505
The Settings subpage in the Dashboard allows you to view the Organization ID and Name and to delete the Organization if you don't need it anymore. This action is irreversible, so please proceed with caution. Personal Organizations are there by default and cannot be deleted.
1506
1506
1507
+
title: Other
1508
+
1509
+
import { Tabs, TabItem } from '@astrojs/starlight/components';
1510
+
1511
+
## Region Selection
1512
+
1513
+
Daytona is currently available in the following regions:
1514
+
1515
+
- United States (US)
1516
+
- Europe (EU)
1517
+
1518
+
You can select the region during the Daytona [configuration](/docs/configuration) step.
1519
+
1520
+
```python
1521
+
from daytona_sdk import Daytona, DaytonaConfig, SandboxTargetRegion
1522
+
1523
+
config = DaytonaConfig(
1524
+
target=SandboxTargetRegion.US
1525
+
)
1526
+
1527
+
daytona = Daytona(config)
1528
+
1529
+
```
1530
+
1531
+
```typescript
1532
+
import { Daytona, SandboxTargetRegion } from '@daytonaio/sdk';
1533
+
1534
+
const daytona: Daytona = new Daytona({
1535
+
target: SandboxTargetRegion.US
1536
+
});
1537
+
```
1538
+
1507
1539
title: Process and Code Execution
1508
1540
1509
1541
import { Tabs, TabItem } from '@astrojs/starlight/components';
Daytona keeps a pool of ready-to-go "warm" Sandboxes. When available, they are automatically used if a custom ID _isn't_ provided and the default image is used, reducing the creation time down to a fraction of a second.
1794
1826
:::
1795
1827
1828
+
### Sandbox Resources
1829
+
1830
+
You can configure the compute resources allocated to your Sandbox using the `SandboxResources` class. This allows you to specify the number of CPU cores, the memory and disk space.
1831
+
1832
+
```python
1833
+
from daytona_sdk import Daytona, CreateSandboxParams, SandboxResources
1834
+
1835
+
daytona = Daytona()
1836
+
1837
+
# Create a Sandbox with custom resources
1838
+
1839
+
resources = SandboxResources(
1840
+
cpu=2, # 2 CPU cores
1841
+
memory=4, # 4GB RAM
1842
+
disk=20, # 20GB disk space
1843
+
)
1844
+
1845
+
params = CreateSandboxParams(
1846
+
language="python",
1847
+
resources=resources
1848
+
)
1849
+
1850
+
sandbox = daytona.create(params)
1851
+
1852
+
```
1853
+
```typescript
1854
+
import { Daytona } from '@daytonaio/sdk';
1855
+
1856
+
const daytona = new Daytona();
1857
+
1858
+
// Create a Sandbox with custom resources
1859
+
const sandbox = await daytona.create({
1860
+
language: 'typescript',
1861
+
resources: {
1862
+
cpu: 2, // 2 CPU cores
1863
+
memory: 4, // 4GB RAM
1864
+
disk: 20, // 20GB disk space
1865
+
}
1866
+
});
1867
+
```
1868
+
1869
+
1870
+
:::note
1871
+
All resource parameters are optional. If not specified, Daytona will use default values appropriate for the selected language and use case.
1872
+
:::
1873
+
1796
1874
## Sandbox Information
1797
1875
1798
1876
Daytona SDK provides methods to get information about a Sandbox, such as ID, root directory, and status using Python and TypeScript.
@@ -1811,10 +1889,6 @@ name = sandbox.instance.name
1811
1889
image = sandbox.instance.image
1812
1890
state = sandbox.instance.state
1813
1891
1814
-
# Get the preview link for an app running on port 3000
1815
-
1816
-
preview_link = sandbox.get_preview_link(3000)
1817
-
1818
1892
```
1819
1893
```typescript
1820
1894
// Get Sandbox ID
@@ -1828,7 +1902,22 @@ const name = sandbox.instance.name
1828
1902
const image = sandbox.instance.image
1829
1903
const state = sandbox.instance.state
1830
1904
1905
+
```
1906
+
1907
+
1908
+
### Sandbox Preview Port
1909
+
1910
+
Daytona SDK also provides a method to get the preview port for the Sandbox.
1911
+
1912
+
```python
1913
+
# Get the preview link for an app running on port 3000
1914
+
1915
+
preview_link = sandbox.get_preview_link(3000)
1916
+
1917
+
```
1918
+
```typescript
1831
1919
// Get the preview link for an app running on port 3000
0 commit comments