Open-source, secure environment with real-world tools for enterprise-grade agents.
Python agentaiai-agentai-agentscode-interpretercopilotdevelopmentdevtoolsgptgpt-4javascriptllmnextjsopenaipythonreactsoftwaretypescript
Synced spec + generated API client (#889)
Mish Ushakov67070bb9ea40
diff --git a/.changeset/quick-emus-tell.md b/.changeset/quick-emus-tell.mdnew file mode 100644index 000000000..5a5870342--- /dev/null+++ b/.changeset/quick-emus-tell.md@@ -0,0 +1,7 @@+---+'@e2b/python-sdk': patch+'e2b': patch+'@e2b/cli': patch+---++updated spec, regenerated clientsdiff --git a/packages/cli/src/utils/format.ts b/packages/cli/src/utils/format.tsindex ad0842a5e..53b8825fd 100644--- a/packages/cli/src/utils/format.ts+++ b/packages/cli/src/utils/format.ts@@ -29,10 +29,9 @@ export function asFormattedTeam(}export function asFormattedSandboxTemplate(- template: Pick<- e2b.components['schemas']['Template'],- 'templateID' | 'aliases'- >,+ template: Pick<e2b.components['schemas']['Template'], 'templateID'> & {+ aliases?: e2b.components['schemas']['Template']['aliases']+ },configLocalPath?: string) {const aliases = listAliases(template.aliases)diff --git a/packages/js-sdk/src/api/schema.gen.ts b/packages/js-sdk/src/api/schema.gen.tsindex 85f2d7d0b..ee1445701 100644--- a/packages/js-sdk/src/api/schema.gen.ts+++ b/packages/js-sdk/src/api/schema.gen.ts@@ -961,6 +961,19 @@ export interface paths {export type webhooks = Record<string, never>export interface components {schemas: {+ AWSRegistry: {+ /** @description AWS Access Key ID for ECR authentication */+ awsAccessKeyId: string+ /** @description AWS Region where the ECR registry is located */+ awsRegion: string+ /** @description AWS Secret Access Key for ECR authentication */+ awsSecretAccessKey: string+ /**+ * @description Type of registry authentication (enum property replaced by openapi-typescript)+ * @enum {string}+ */+ type: 'aws'+ }BuildLogEntry: {level: components['schemas']['LogLevel']/** @description Log message content */@@ -1059,6 +1072,30 @@ export interface components {/** @description Error */message: string}+ FromImageRegistry:+ | components['schemas']['AWSRegistry']+ | components['schemas']['GCPRegistry']+ | components['schemas']['GeneralRegistry']+ GCPRegistry: {+ /** @description Service Account JSON for GCP authentication */+ serviceAccountJson: string+ /**+ * @description Type of registry authentication (enum property replaced by openapi-typescript)+ * @enum {string}+ */+ type: 'gcp'+ }+ GeneralRegistry: {+ /** @description Password to use for the registry */+ password: string+ /**+ * @description Type of registry authentication (enum property replaced by openapi-typescript)+ * @enum {string}+ */+ type: 'registry'+ /** @description Username to use for the registry */+ username: string+ }IdentifierMaskingDetails: {/** @description Prefix used in masked version of the token or key */maskedValuePrefix: string@@ -1152,8 +1189,13 @@ export interface components {* @description Number of sandbox create successes*/createSuccesses: number- metrics: components['schemas']['NodeMetrics']/** @description Identifier of the node */+ id: string+ metrics: components['schemas']['NodeMetrics']+ /**+ * @deprecated+ * @description Identifier of the nomad node+ */nodeID: string/*** Format: uint32@@ -1165,6 +1207,8 @@ export interface components {* @description Number of starting Sandboxes*/sandboxStartingCount: number+ /** @description Service instance identifier of the node */+ serviceInstanceID: stringstatus: components['schemas']['NodeStatus']/** @description Version of the orchestrator */version: string@@ -1186,11 +1230,18 @@ export interface components {* @description Number of sandbox create successes*/createSuccesses: number- metrics: components['schemas']['NodeMetrics']/** @description Identifier of the node */+ id: string+ metrics: components['schemas']['NodeMetrics']+ /**+ * @deprecated+ * @description Identifier of the nomad node+ */nodeID: string/** @description List of sandboxes running on the node */sandboxes: components['schemas']['ListedSandbox'][]+ /** @description Service instance identifier of the node */+ serviceInstanceID: stringstatus: components['schemas']['NodeStatus']/** @description Version of the orchestrator */version: string@@ -1442,7 +1493,7 @@ export interface components {}Template: {/** @description Aliases of the template */- aliases?: string[]+ aliases: string[]/*** Format: int32* @description Number of times the template was built@@ -1463,7 +1514,7 @@ export interface components {* Format: date-time* @description Time when the template was last used*/- lastSpawnedAt: string+ lastSpawnedAt: string | nullmemoryMB: components['schemas']['MemoryMB']/** @description Whether the template is public or only accessible by the team */public: boolean@@ -1538,6 +1589,7 @@ export interface components {force: boolean/** @description Image to use as a base for the template build */fromImage?: string+ fromImageRegistry?: components['schemas']['FromImageRegistry']/** @description Template to use as a base for the template build */fromTemplate?: string/** @description Ready check command to execute in the template after the build */diff --git a/packages/python-sdk/e2b/api/client/models/__init__.py b/packages/python-sdk/e2b/api/client/models/__init__.pyindex f0183ee15..b7299ce2f 100644--- a/packages/python-sdk/e2b/api/client/models/__init__.py+++ b/packages/python-sdk/e2b/api/client/models/__init__.py@@ -1,11 +1,17 @@"""Contains all the data models used in inputs/outputs"""+from .aws_registry import AWSRegistry+from .aws_registry_type import AWSRegistryTypefrom .build_log_entry import BuildLogEntryfrom .build_status_reason import BuildStatusReasonfrom .created_access_token import CreatedAccessTokenfrom .created_team_api_key import CreatedTeamAPIKeyfrom .disk_metrics import DiskMetricsfrom .error import Error+from .gcp_registry import GCPRegistry+from .gcp_registry_type import GCPRegistryType+from .general_registry import GeneralRegistry+from .general_registry_type import GeneralRegistryTypefrom .identifier_masking_details import IdentifierMaskingDetailsfrom .listed_sandbox import ListedSandboxfrom .log_level import LogLevel@@ -47,12 +53,18 @@ from .template_update_request import TemplateUpdateRequestfrom .update_team_api_key import UpdateTeamAPIKey__all__ = (+ "AWSRegistry",+ "AWSRegistryType","BuildLogEntry","BuildStatusReason","CreatedAccessToken","CreatedTeamAPIKey","DiskMetrics","Error",+ "GCPRegistry",+ "GCPRegistryType",+ "GeneralRegistry",+ "GeneralRegistryType","IdentifierMaskingDetails","ListedSandbox","LogLevel",diff --git a/packages/python-sdk/e2b/api/client/models/aws_registry.py b/packages/python-sdk/e2b/api/client/models/aws_registry.pynew file mode 100644index 000000000..ef1ea9748--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/aws_registry.py@@ -0,0 +1,85 @@+from collections.abc import Mapping+from typing import Any, TypeVar++from attrs import define as _attrs_define+from attrs import field as _attrs_field++from ..models.aws_registry_type import AWSRegistryType++T = TypeVar("T", bound="AWSRegistry")+++@_attrs_define+class AWSRegistry:+ """+ Attributes:+ aws_access_key_id (str): AWS Access Key ID for ECR authentication+ aws_region (str): AWS Region where the ECR registry is located+ aws_secret_access_key (str): AWS Secret Access Key for ECR authentication+ type_ (AWSRegistryType): Type of registry authentication+ """++ aws_access_key_id: str+ aws_region: str+ aws_secret_access_key: str+ type_: AWSRegistryType+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)++ def to_dict(self) -> dict[str, Any]:+ aws_access_key_id = self.aws_access_key_id++ aws_region = self.aws_region++ aws_secret_access_key = self.aws_secret_access_key++ type_ = self.type_.value++ field_dict: dict[str, Any] = {}+ field_dict.update(self.additional_properties)+ field_dict.update(+ {+ "awsAccessKeyId": aws_access_key_id,+ "awsRegion": aws_region,+ "awsSecretAccessKey": aws_secret_access_key,+ "type": type_,+ }+ )++ return field_dict++ @classmethod+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:+ d = dict(src_dict)+ aws_access_key_id = d.pop("awsAccessKeyId")++ aws_region = d.pop("awsRegion")++ aws_secret_access_key = d.pop("awsSecretAccessKey")++ type_ = AWSRegistryType(d.pop("type"))++ aws_registry = cls(+ aws_access_key_id=aws_access_key_id,+ aws_region=aws_region,+ aws_secret_access_key=aws_secret_access_key,+ type_=type_,+ )++ aws_registry.additional_properties = d+ return aws_registry++ @property+ def additional_keys(self) -> list[str]:+ return list(self.additional_properties.keys())++ def __getitem__(self, key: str) -> Any:+ return self.additional_properties[key]++ def __setitem__(self, key: str, value: Any) -> None:+ self.additional_properties[key] = value++ def __delitem__(self, key: str) -> None:+ del self.additional_properties[key]++ def __contains__(self, key: str) -> bool:+ return key in self.additional_propertiesdiff --git a/packages/python-sdk/e2b/api/client/models/aws_registry_type.py b/packages/python-sdk/e2b/api/client/models/aws_registry_type.pynew file mode 100644index 000000000..6815bbc06--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/aws_registry_type.py@@ -0,0 +1,8 @@+from enum import Enum+++class AWSRegistryType(str, Enum):+ AWS = "aws"++ def __str__(self) -> str:+ return str(self.value)diff --git a/packages/python-sdk/e2b/api/client/models/gcp_registry.py b/packages/python-sdk/e2b/api/client/models/gcp_registry.pynew file mode 100644index 000000000..01b6ded00--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/gcp_registry.py@@ -0,0 +1,69 @@+from collections.abc import Mapping+from typing import Any, TypeVar++from attrs import define as _attrs_define+from attrs import field as _attrs_field++from ..models.gcp_registry_type import GCPRegistryType++T = TypeVar("T", bound="GCPRegistry")+++@_attrs_define+class GCPRegistry:+ """+ Attributes:+ service_account_json (str): Service Account JSON for GCP authentication+ type_ (GCPRegistryType): Type of registry authentication+ """++ service_account_json: str+ type_: GCPRegistryType+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)++ def to_dict(self) -> dict[str, Any]:+ service_account_json = self.service_account_json++ type_ = self.type_.value++ field_dict: dict[str, Any] = {}+ field_dict.update(self.additional_properties)+ field_dict.update(+ {+ "serviceAccountJson": service_account_json,+ "type": type_,+ }+ )++ return field_dict++ @classmethod+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:+ d = dict(src_dict)+ service_account_json = d.pop("serviceAccountJson")++ type_ = GCPRegistryType(d.pop("type"))++ gcp_registry = cls(+ service_account_json=service_account_json,+ type_=type_,+ )++ gcp_registry.additional_properties = d+ return gcp_registry++ @property+ def additional_keys(self) -> list[str]:+ return list(self.additional_properties.keys())++ def __getitem__(self, key: str) -> Any:+ return self.additional_properties[key]++ def __setitem__(self, key: str, value: Any) -> None:+ self.additional_properties[key] = value++ def __delitem__(self, key: str) -> None:+ del self.additional_properties[key]++ def __contains__(self, key: str) -> bool:+ return key in self.additional_propertiesdiff --git a/packages/python-sdk/e2b/api/client/models/gcp_registry_type.py b/packages/python-sdk/e2b/api/client/models/gcp_registry_type.pynew file mode 100644index 000000000..e9c8aa5f0--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/gcp_registry_type.py@@ -0,0 +1,8 @@+from enum import Enum+++class GCPRegistryType(str, Enum):+ GCP = "gcp"++ def __str__(self) -> str:+ return str(self.value)diff --git a/packages/python-sdk/e2b/api/client/models/general_registry.py b/packages/python-sdk/e2b/api/client/models/general_registry.pynew file mode 100644index 000000000..38bc1795d--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/general_registry.py@@ -0,0 +1,77 @@+from collections.abc import Mapping+from typing import Any, TypeVar++from attrs import define as _attrs_define+from attrs import field as _attrs_field++from ..models.general_registry_type import GeneralRegistryType++T = TypeVar("T", bound="GeneralRegistry")+++@_attrs_define+class GeneralRegistry:+ """+ Attributes:+ password (str): Password to use for the registry+ type_ (GeneralRegistryType): Type of registry authentication+ username (str): Username to use for the registry+ """++ password: str+ type_: GeneralRegistryType+ username: str+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)++ def to_dict(self) -> dict[str, Any]:+ password = self.password++ type_ = self.type_.value++ username = self.username++ field_dict: dict[str, Any] = {}+ field_dict.update(self.additional_properties)+ field_dict.update(+ {+ "password": password,+ "type": type_,+ "username": username,+ }+ )++ return field_dict++ @classmethod+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:+ d = dict(src_dict)+ password = d.pop("password")++ type_ = GeneralRegistryType(d.pop("type"))++ username = d.pop("username")++ general_registry = cls(+ password=password,+ type_=type_,+ username=username,+ )++ general_registry.additional_properties = d+ return general_registry++ @property+ def additional_keys(self) -> list[str]:+ return list(self.additional_properties.keys())++ def __getitem__(self, key: str) -> Any:+ return self.additional_properties[key]++ def __setitem__(self, key: str, value: Any) -> None:+ self.additional_properties[key] = value++ def __delitem__(self, key: str) -> None:+ del self.additional_properties[key]++ def __contains__(self, key: str) -> bool:+ return key in self.additional_propertiesdiff --git a/packages/python-sdk/e2b/api/client/models/general_registry_type.py b/packages/python-sdk/e2b/api/client/models/general_registry_type.pynew file mode 100644index 000000000..d89e7846a--- /dev/null+++ b/packages/python-sdk/e2b/api/client/models/general_registry_type.py@@ -0,0 +1,8 @@+from enum import Enum+++class GeneralRegistryType(str, Enum):+ REGISTRY = "registry"++ def __str__(self) -> str:+ return str(self.value)diff --git a/packages/python-sdk/e2b/api/client/models/node.py b/packages/python-sdk/e2b/api/client/models/node.pyindex 8974fb283..d50936958 100644--- a/packages/python-sdk/e2b/api/client/models/node.py+++ b/packages/python-sdk/e2b/api/client/models/node.py@@ -21,10 +21,12 @@ class Node:commit (str): Commit of the orchestratorcreate_fails (int): Number of sandbox create failscreate_successes (int): Number of sandbox create successes+ id (str): Identifier of the nodemetrics (NodeMetrics): Node metrics- node_id (str): Identifier of the node+ node_id (str): Identifier of the nomad nodesandbox_count (int): Number of sandboxes running on the nodesandbox_starting_count (int): Number of starting Sandboxes+ service_instance_id (str): Service instance identifier of the nodestatus (NodeStatus): Status of the nodeversion (str): Version of the orchestrator"""@@ -33,10 +35,12 @@ class Node:commit: strcreate_fails: intcreate_successes: int+ id: strmetrics: "NodeMetrics"node_id: strsandbox_count: intsandbox_starting_count: int+ service_instance_id: strstatus: NodeStatusversion: stradditional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)@@ -50,6 +54,8 @@ class Node:create_successes = self.create_successes+ id = self.id+metrics = self.metrics.to_dict()node_id = self.node_id@@ -58,6 +64,8 @@ class Node:sandbox_starting_count = self.sandbox_starting_count+ service_instance_id = self.service_instance_id+status = self.status.valueversion = self.version@@ -70,10 +78,12 @@ class Node:"commit": commit,"createFails": create_fails,"createSuccesses": create_successes,+ "id": id,"metrics": metrics,"nodeID": node_id,"sandboxCount": sandbox_count,"sandboxStartingCount": sandbox_starting_count,+ "serviceInstanceID": service_instance_id,"status": status,"version": version,}@@ -94,6 +104,8 @@ class Node:create_successes = d.pop("createSuccesses")+ id = d.pop("id")+metrics = NodeMetrics.from_dict(d.pop("metrics"))node_id = d.pop("nodeID")@@ -102,6 +114,8 @@ class Node:sandbox_starting_count = d.pop("sandboxStartingCount")+ service_instance_id = d.pop("serviceInstanceID")+status = NodeStatus(d.pop("status"))version = d.pop("version")@@ -111,10 +125,12 @@ class Node:commit=commit,create_fails=create_fails,create_successes=create_successes,+ id=id,metrics=metrics,node_id=node_id,sandbox_count=sandbox_count,sandbox_starting_count=sandbox_starting_count,+ service_instance_id=service_instance_id,status=status,version=version,)diff --git a/packages/python-sdk/e2b/api/client/models/node_detail.py b/packages/python-sdk/e2b/api/client/models/node_detail.pyindex 36b7a6a62..352ead6d5 100644--- a/packages/python-sdk/e2b/api/client/models/node_detail.py+++ b/packages/python-sdk/e2b/api/client/models/node_detail.py@@ -23,9 +23,11 @@ class NodeDetail:commit (str): Commit of the orchestratorcreate_fails (int): Number of sandbox create failscreate_successes (int): Number of sandbox create successes+ id (str): Identifier of the nodemetrics (NodeMetrics): Node metrics- node_id (str): Identifier of the node+ node_id (str): Identifier of the nomad nodesandboxes (list['ListedSandbox']): List of sandboxes running on the node+ service_instance_id (str): Service instance identifier of the nodestatus (NodeStatus): Status of the nodeversion (str): Version of the orchestrator"""@@ -35,9 +37,11 @@ class NodeDetail:commit: strcreate_fails: intcreate_successes: int+ id: strmetrics: "NodeMetrics"node_id: strsandboxes: list["ListedSandbox"]+ service_instance_id: strstatus: NodeStatusversion: stradditional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)@@ -53,6 +57,8 @@ class NodeDetail:create_successes = self.create_successes+ id = self.id+metrics = self.metrics.to_dict()node_id = self.node_id@@ -62,6 +68,8 @@ class NodeDetail:sandboxes_item = sandboxes_item_data.to_dict()sandboxes.append(sandboxes_item)+ service_instance_id = self.service_instance_id+status = self.status.valueversion = self.version@@ -75,9 +83,11 @@ class NodeDetail:"commit": commit,"createFails": create_fails,"createSuccesses": create_successes,+ "id": id,"metrics": metrics,"nodeID": node_id,"sandboxes": sandboxes,+ "serviceInstanceID": service_instance_id,"status": status,"version": version,}@@ -101,6 +111,8 @@ class NodeDetail:create_successes = d.pop("createSuccesses")+ id = d.pop("id")+metrics = NodeMetrics.from_dict(d.pop("metrics"))node_id = d.pop("nodeID")@@ -112,6 +124,8 @@ class NodeDetail:sandboxes.append(sandboxes_item)+ service_instance_id = d.pop("serviceInstanceID")+status = NodeStatus(d.pop("status"))version = d.pop("version")@@ -122,9 +136,11 @@ class NodeDetail:commit=commit,create_fails=create_fails,create_successes=create_successes,+ id=id,metrics=metrics,node_id=node_id,sandboxes=sandboxes,+ service_instance_id=service_instance_id,status=status,version=version,)diff --git a/packages/python-sdk/e2b/api/client/models/template.py b/packages/python-sdk/e2b/api/client/models/template.pyindex 31f7a84bd..a3a4bfdc4 100644--- a/packages/python-sdk/e2b/api/client/models/template.py+++ b/packages/python-sdk/e2b/api/client/models/template.py@@ -6,8 +6,6 @@ from attrs import define as _attrs_definefrom attrs import field as _attrs_fieldfrom dateutil.parser import isoparse-from ..types import UNSET, Unset-if TYPE_CHECKING:from ..models.team_user import TeamUser@@ -19,6 +17,7 @@ T = TypeVar("T", bound="Template")class Template:"""Attributes:+ aliases (list[str]): Aliases of the templatebuild_count (int): Number of times the template was builtbuild_id (str): Identifier of the last successful build for given templatecpu_count (int): CPU cores for the sandbox@@ -26,15 +25,15 @@ class Template:created_by (Union['TeamUser', None]):disk_size_mb (int): Disk size for the sandbox in MiBenvd_version (str): Version of the envd running in the sandbox- last_spawned_at (datetime.datetime): Time when the template was last used+ last_spawned_at (Union[None, datetime.datetime]): Time when the template was last usedmemory_mb (int): Memory for the sandbox in MiBpublic (bool): Whether the template is public or only accessible by the teamspawn_count (int): Number of times the template was usedtemplate_id (str): Identifier of the templateupdated_at (datetime.datetime): Time when the template was last updated- aliases (Union[Unset, list[str]]): Aliases of the template"""+ aliases: list[str]build_count: intbuild_id: strcpu_count: int@@ -42,18 +41,19 @@ class Template:created_by: Union["TeamUser", None]disk_size_mb: intenvd_version: str- last_spawned_at: datetime.datetime+ last_spawned_at: Union[None, datetime.datetime]memory_mb: intpublic: boolspawn_count: inttemplate_id: strupdated_at: datetime.datetime- aliases: Union[Unset, list[str]] = UNSETadditional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)def to_dict(self) -> dict[str, Any]:from ..models.team_user import TeamUser+ aliases = self.aliases+build_count = self.build_countbuild_id = self.build_id@@ -72,7 +72,11 @@ class Template:envd_version = self.envd_version- last_spawned_at = self.last_spawned_at.isoformat()+ last_spawned_at: Union[None, str]+ if isinstance(self.last_spawned_at, datetime.datetime):+ last_spawned_at = self.last_spawned_at.isoformat()+ else:+ last_spawned_at = self.last_spawned_atmemory_mb = self.memory_mb@@ -84,14 +88,11 @@ class Template:updated_at = self.updated_at.isoformat()- aliases: Union[Unset, list[str]] = UNSET- if not isinstance(self.aliases, Unset):- aliases = self.aliases-field_dict: dict[str, Any] = {}field_dict.update(self.additional_properties)field_dict.update({+ "aliases": aliases,"buildCount": build_count,"buildID": build_id,"cpuCount": cpu_count,@@ -107,8 +108,6 @@ class Template:"updatedAt": updated_at,})- if aliases is not UNSET:- field_dict["aliases"] = aliasesreturn field_dict@@ -117,6 +116,8 @@ class Template:from ..models.team_user import TeamUserd = dict(src_dict)+ aliases = cast(list[str], d.pop("aliases"))+build_count = d.pop("buildCount")build_id = d.pop("buildID")@@ -144,7 +145,20 @@ class Template:envd_version = d.pop("envdVersion")- last_spawned_at = isoparse(d.pop("lastSpawnedAt"))+ def _parse_last_spawned_at(data: object) -> Union[None, datetime.datetime]:+ if data is None:+ return data+ try:+ if not isinstance(data, str):+ raise TypeError()+ last_spawned_at_type_0 = isoparse(data)++ return last_spawned_at_type_0+ except: # noqa: E722+ pass+ return cast(Union[None, datetime.datetime], data)++ last_spawned_at = _parse_last_spawned_at(d.pop("lastSpawnedAt"))memory_mb = d.pop("memoryMB")@@ -156,9 +170,8 @@ class Template:updated_at = isoparse(d.pop("updatedAt"))- aliases = cast(list[str], d.pop("aliases", UNSET))-template = cls(+ aliases=aliases,build_count=build_count,build_id=build_id,cpu_count=cpu_count,@@ -172,7 +185,6 @@ class Template:spawn_count=spawn_count,template_id=template_id,updated_at=updated_at,- aliases=aliases,)template.additional_properties = ddiff --git a/packages/python-sdk/e2b/api/client/models/template_build_start_v2.py b/packages/python-sdk/e2b/api/client/models/template_build_start_v2.pyindex 5f00502d3..32adf844e 100644--- a/packages/python-sdk/e2b/api/client/models/template_build_start_v2.py+++ b/packages/python-sdk/e2b/api/client/models/template_build_start_v2.py@@ -7,6 +7,9 @@ from attrs import field as _attrs_fieldfrom ..types import UNSET, Unsetif TYPE_CHECKING:+ from ..models.aws_registry import AWSRegistry+ from ..models.gcp_registry import GCPRegistry+ from ..models.general_registry import GeneralRegistryfrom ..models.template_step import TemplateStep@@ -20,6 +23,7 @@ class TemplateBuildStartV2:force (Union[Unset, bool]): Whether the whole build should be forced to run regardless of the cache Default:False.from_image (Union[Unset, str]): Image to use as a base for the template build+ from_image_registry (Union['AWSRegistry', 'GCPRegistry', 'GeneralRegistry', Unset]):from_template (Union[Unset, str]): Template to use as a base for the template buildready_cmd (Union[Unset, str]): Ready check command to execute in the template after the buildstart_cmd (Union[Unset, str]): Start command to execute in the template after the build@@ -28,6 +32,9 @@ class TemplateBuildStartV2:force: Union[Unset, bool] = Falsefrom_image: Union[Unset, str] = UNSET+ from_image_registry: Union[+ "AWSRegistry", "GCPRegistry", "GeneralRegistry", Unset+ ] = UNSETfrom_template: Union[Unset, str] = UNSETready_cmd: Union[Unset, str] = UNSETstart_cmd: Union[Unset, str] = UNSET@@ -35,10 +42,23 @@ class TemplateBuildStartV2:additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)def to_dict(self) -> dict[str, Any]:+ from ..models.aws_registry import AWSRegistry+ from ..models.gcp_registry import GCPRegistry+force = self.forcefrom_image = self.from_image+ from_image_registry: Union[Unset, dict[str, Any]]+ if isinstance(self.from_image_registry, Unset):+ from_image_registry = UNSET+ elif isinstance(self.from_image_registry, AWSRegistry):+ from_image_registry = self.from_image_registry.to_dict()+ elif isinstance(self.from_image_registry, GCPRegistry):+ from_image_registry = self.from_image_registry.to_dict()+ else:+ from_image_registry = self.from_image_registry.to_dict()+from_template = self.from_templateready_cmd = self.ready_cmd@@ -59,6 +79,8 @@ class TemplateBuildStartV2:field_dict["force"] = forceif from_image is not UNSET:field_dict["fromImage"] = from_image+ if from_image_registry is not UNSET:+ field_dict["fromImageRegistry"] = from_image_registryif from_template is not UNSET:field_dict["fromTemplate"] = from_templateif ready_cmd is not UNSET:@@ -72,6 +94,9 @@ class TemplateBuildStartV2:@classmethoddef from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:+ from ..models.aws_registry import AWSRegistry+ from ..models.gcp_registry import GCPRegistry+ from ..models.general_registry import GeneralRegistryfrom ..models.template_step import TemplateStepd = dict(src_dict)@@ -79,6 +104,43 @@ class TemplateBuildStartV2:from_image = d.pop("fromImage", UNSET)+ def _parse_from_image_registry(+ data: object,+ ) -> Union["AWSRegistry", "GCPRegistry", "GeneralRegistry", Unset]:+ if isinstance(data, Unset):+ return data+ try:+ if not isinstance(data, dict):+ raise TypeError()+ componentsschemas_from_image_registry_type_0 = AWSRegistry.from_dict(+ data+ )++ return componentsschemas_from_image_registry_type_0+ except: # noqa: E722+ pass+ try:+ if not isinstance(data, dict):+ raise TypeError()+ componentsschemas_from_image_registry_type_1 = GCPRegistry.from_dict(+ data+ )++ return componentsschemas_from_image_registry_type_1+ except: # noqa: E722+ pass+ if not isinstance(data, dict):+ raise TypeError()+ componentsschemas_from_image_registry_type_2 = GeneralRegistry.from_dict(+ data+ )++ return componentsschemas_from_image_registry_type_2++ from_image_registry = _parse_from_image_registry(+ d.pop("fromImageRegistry", UNSET)+ )+from_template = d.pop("fromTemplate", UNSET)ready_cmd = d.pop("readyCmd", UNSET)@@ -95,6 +157,7 @@ class TemplateBuildStartV2:template_build_start_v2 = cls(force=force,from_image=from_image,+ from_image_registry=from_image_registry,from_template=from_template,ready_cmd=ready_cmd,start_cmd=start_cmd,diff --git a/spec/openapi.yml b/spec/openapi.ymlindex c2da79859..80f9c9617 100644--- a/spec/openapi.yml+++ b/spec/openapi.yml@@ -499,6 +499,7 @@ components:- spawnCount- buildCount- envdVersion+ - aliasesproperties:templateID:type: string@@ -534,6 +535,7 @@ components:nullable: truelastSpawnedAt:type: string+ nullable: trueformat: date-timedescription: Time when the template was last usedspawnCount:@@ -608,6 +610,72 @@ components:memoryMB:$ref: "#/components/schemas/MemoryMB"+ FromImageRegistry:+ oneOf:+ - $ref: '#/components/schemas/AWSRegistry'+ - $ref: '#/components/schemas/GCPRegistry'+ - $ref: '#/components/schemas/GeneralRegistry'+ discriminator:+ propertyName: type+ mapping:+ aws: '#/components/schemas/AWSRegistry'+ gcp: '#/components/schemas/GCPRegistry'+ registry: '#/components/schemas/GeneralRegistry'++ AWSRegistry:+ type: object+ required:+ - type+ - awsAccessKeyId+ - awsSecretAccessKey+ - awsRegion+ properties:+ type:+ type: string+ enum: [aws]+ description: Type of registry authentication+ awsAccessKeyId:+ type: string+ description: AWS Access Key ID for ECR authentication+ awsSecretAccessKey:+ type: string+ description: AWS Secret Access Key for ECR authentication+ awsRegion:+ type: string+ description: AWS Region where the ECR registry is located++ GCPRegistry:+ type: object+ required:+ - type+ - serviceAccountJson+ properties:+ type:+ type: string+ enum: [gcp]+ description: Type of registry authentication+ serviceAccountJson:+ type: string+ description: Service Account JSON for GCP authentication++ GeneralRegistry:+ type: object+ required:+ - type+ - username+ - password+ properties:+ type:+ type: string+ enum: [registry]+ description: Type of registry authentication+ username:+ type: string+ description: Username to use for the registry+ password:+ type: string+ description: Password to use for the registry+TemplateBuildStartV2:type: objectproperties:@@ -617,6 +685,8 @@ components:fromTemplate:type: stringdescription: Template to use as a base for the template build+ fromImageRegistry:+ $ref: "#/components/schemas/FromImageRegistry"force:default: falsetype: boolean@@ -809,6 +879,8 @@ components:Node:required:- nodeID+ - id+ - serviceInstanceID- clusterID- status- sandboxCount@@ -826,8 +898,15 @@ components:type: stringdescription: Commit of the orchestratornodeID:+ type: string+ deprecated: true+ description: Identifier of the nomad node+ id:type: stringdescription: Identifier of the node+ serviceInstanceID:+ type: string+ description: Service instance identifier of the nodeclusterID:type: stringdescription: Identifier of the cluster@@ -855,6 +934,8 @@ components:NodeDetail:required:- nodeID+ - id+ - serviceInstanceID- clusterID- status- sandboxes@@ -874,9 +955,16 @@ components:commit:type: stringdescription: Commit of the orchestrator- nodeID:+ id:type: stringdescription: Identifier of the node+ serviceInstanceID:+ type: string+ description: Service instance identifier of the node+ nodeID:+ type: string+ deprecated: true+ description: Identifier of the nomad nodestatus:$ref: "#/components/schemas/NodeStatus"sandboxes:@@ -1809,6 +1897,12 @@ paths:- AdminTokenAuth: []parameters:- $ref: "#/components/parameters/nodeID"+ - in: query+ name: clusterID+ description: Identifier of the cluster+ required: false+ schema:+ type: stringresponses:"200":description: Successfully returned the node