From 3257ec84dfde27683909105d601df14ed661c0c4 Mon Sep 17 00:00:00 2001 From: abonneth <206544678+abonneth@users.noreply.github.com> Date: Thu, 15 Oct 2026 13:50:42 +0000 Subject: [PATCH] chore(sdk): sync generated SDK (v1.2.5) --- openapi.json | 134 +++++++++++++++++- pyproject.toml | 2 +- src/hai_agents/core/client_wrapper.py | 4 +- src/hai_agents/environments/client.py | 16 +++ src/hai_agents/environments/raw_client.py | 16 +++ .../types/create_environment_request.py | 3 + .../types/update_environment_request_body.py | 3 + src/hai_agents/sessions/client.py | 8 +- src/hai_agents/sessions/raw_client.py | 8 +- src/hai_agents/skills/client.py | 72 ++++++++++ src/hai_agents/skills/raw_client.py | 72 ++++++++++ src/hai_agents/types/browser.py | 5 + src/hai_agents/types/desktop.py | 10 ++ src/hai_agents/types/environment.py | 3 + src/hai_agents/types/session_request.py | 4 +- src/hai_agents/types/skill.py | 6 +- src/hai_agents/types/workstation.py | 2 +- uv.lock | 2 +- 18 files changed, 350 insertions(+), 20 deletions(-) diff --git a/openapi.json b/openapi.json index 5c0b444..80db169 100644 --- a/openapi.json +++ b/openapi.json @@ -5135,6 +5135,14 @@ "description": "Provision on the agent's first use instead of at startup. Skips the initial observation.", "default": false }, + "settle_s": { + "type": "number", + "maximum": 10.0, + "minimum": 0.0, + "title": "Settle S", + "description": "Seconds to wait after each page action.", + "default": 1.0 + }, "vault_id": { "anyOf": [ { @@ -5637,6 +5645,28 @@ "title": "Lazy", "description": "Provision on the agent's first use instead of at startup. Skips the initial observation.", "default": false + }, + "settle_s": { + "type": "number", + "maximum": 10.0, + "minimum": 0.0, + "title": "Settle S", + "description": "Seconds to wait after each input action.", + "default": 0.5 + }, + "screenshot_max_width": { + "anyOf": [ + { + "type": "integer", + "maximum": 1920.0, + "exclusiveMinimum": 0.0 + }, + { + "type": "null" + } + ], + "title": "Screenshot Max Width", + "description": "Maximum screenshot width in pixels. Null uses the host default; images are never upscaled." } }, "type": "object", @@ -6927,6 +6957,19 @@ ], "title": "Lazy" }, + "settle_s": { + "anyOf": [ + { + "type": "number", + "maximum": 10.0, + "minimum": 0.0 + }, + { + "type": "null" + } + ], + "title": "Settle S" + }, "vault_id": { "anyOf": [ { @@ -6983,6 +7026,19 @@ } ] }, + "screenshot_max_width": { + "anyOf": [ + { + "type": "integer", + "maximum": 1920.0, + "exclusiveMinimum": 0.0 + }, + { + "type": "null" + } + ], + "title": "Screenshot Max Width" + }, "image": { "anyOf": [ { @@ -7048,6 +7104,47 @@ } ], "title": "Url Pattern" + }, + "compatibility": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Compatibility" + }, + "files": { + "anyOf": [ + { + "additionalProperties": { + "type": "string", + "contentMediaType": "application/octet-stream" + }, + "type": "object", + "maxProperties": 511 + }, + { + "type": "null" + } + ], + "title": "Files" + }, + "executable_files": { + "anyOf": [ + { + "items": { + "type": "string" + }, + "type": "array" + }, + { + "type": "null" + } + ], + "title": "Executable Files" } }, "type": "object", @@ -7839,7 +7936,7 @@ } ], "title": "Delete After Min", - "description": "Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever.", + "description": "Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy.", "default": 43200 }, "delete_screenshot_after_min": { @@ -7853,7 +7950,7 @@ } ], "title": "Delete Screenshot After Min", - "description": "Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime.", + "description": "Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier.", "default": 43200 }, "queue": { @@ -8140,6 +8237,35 @@ ], "title": "Url Pattern", "description": "Optional regex hinting at URLs where this skill applies." + }, + "compatibility": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "null" + } + ], + "title": "Compatibility" + }, + "files": { + "additionalProperties": { + "type": "string", + "contentEncoding": "base64", + "contentMediaType": "application/octet-stream" + }, + "type": "object", + "maxProperties": 511, + "title": "Files" + }, + "executable_files": { + "items": { + "type": "string" + }, + "type": "array", + "title": "Executable Files", + "default": [] } }, "type": "object", @@ -8149,7 +8275,7 @@ "body" ], "title": "Skill", - "description": "A named, reusable instruction an agent can draw on during a session." + "description": "Named instructions with optional scripts, references, and assets." }, "TokenQuotaStatus": { "properties": { @@ -9105,7 +9231,7 @@ "lazy": { "type": "boolean", "title": "Lazy", - "description": "Provision on the agent's first use instead of at startup. Cloud workstations only.", + "description": "Start on the agent's first use instead of at startup. Skips the initial observation. A cloud workstation is provisioned on first use; a user_device one is not probed until then.", "default": false } }, diff --git a/pyproject.toml b/pyproject.toml index c4a3fd6..fcb8fb1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "hai-agents" -version = "1.2.4" +version = "1.2.5" description = "Python SDK for H Company's Agents API: autonomous agents powered by Holo." requires-python = ">=3.10" readme = "README.md" diff --git a/src/hai_agents/core/client_wrapper.py b/src/hai_agents/core/client_wrapper.py index 5467d65..efaf635 100644 --- a/src/hai_agents/core/client_wrapper.py +++ b/src/hai_agents/core/client_wrapper.py @@ -29,9 +29,9 @@ def get_headers(self) -> typing.Dict[str, str]: import platform headers: typing.Dict[str, str] = { - "User-Agent": "hai_agents/1.2.4", + "User-Agent": "hai_agents/1.2.5", "X-HCompany-Client-Name": "hai_agents", - "X-HCompany-Client-Version": "1.2.4", + "X-HCompany-Client-Version": "1.2.5", "X-HCompany-Client-Type": "sdk", "X-HCompany-Language": "Python", "X-HCompany-Runtime": f"python/{platform.python_version()}", diff --git a/src/hai_agents/environments/client.py b/src/hai_agents/environments/client.py index eeb7521..05f38b9 100644 --- a/src/hai_agents/environments/client.py +++ b/src/hai_agents/environments/client.py @@ -232,11 +232,13 @@ def patch_environment( session_id: typing.Optional[str] = OMIT, mode: typing.Optional[PatchEnvironmentMode] = OMIT, lazy: typing.Optional[bool] = OMIT, + settle_s: typing.Optional[float] = OMIT, vault_id: typing.Optional[str] = OMIT, browser_profile_id: typing.Optional[str] = OMIT, use_default_browser_profile: typing.Optional[bool] = OMIT, persist_browser_profile: typing.Optional[bool] = OMIT, network: typing.Optional[BrowserNetwork] = OMIT, + screenshot_max_width: typing.Optional[int] = OMIT, image: typing.Optional[str] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Environment: @@ -259,6 +261,8 @@ def patch_environment( lazy : typing.Optional[bool] + settle_s : typing.Optional[float] + vault_id : typing.Optional[str] browser_profile_id : typing.Optional[str] @@ -269,6 +273,8 @@ def patch_environment( network : typing.Optional[BrowserNetwork] + screenshot_max_width : typing.Optional[int] + image : typing.Optional[str] request_options : typing.Optional[RequestOptions] @@ -298,11 +304,13 @@ def patch_environment( session_id=session_id, mode=mode, lazy=lazy, + settle_s=settle_s, vault_id=vault_id, browser_profile_id=browser_profile_id, use_default_browser_profile=use_default_browser_profile, persist_browser_profile=persist_browser_profile, network=network, + screenshot_max_width=screenshot_max_width, image=image, request_options=request_options, ) @@ -562,11 +570,13 @@ async def patch_environment( session_id: typing.Optional[str] = OMIT, mode: typing.Optional[PatchEnvironmentMode] = OMIT, lazy: typing.Optional[bool] = OMIT, + settle_s: typing.Optional[float] = OMIT, vault_id: typing.Optional[str] = OMIT, browser_profile_id: typing.Optional[str] = OMIT, use_default_browser_profile: typing.Optional[bool] = OMIT, persist_browser_profile: typing.Optional[bool] = OMIT, network: typing.Optional[BrowserNetwork] = OMIT, + screenshot_max_width: typing.Optional[int] = OMIT, image: typing.Optional[str] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Environment: @@ -589,6 +599,8 @@ async def patch_environment( lazy : typing.Optional[bool] + settle_s : typing.Optional[float] + vault_id : typing.Optional[str] browser_profile_id : typing.Optional[str] @@ -599,6 +611,8 @@ async def patch_environment( network : typing.Optional[BrowserNetwork] + screenshot_max_width : typing.Optional[int] + image : typing.Optional[str] request_options : typing.Optional[RequestOptions] @@ -636,11 +650,13 @@ async def main() -> None: session_id=session_id, mode=mode, lazy=lazy, + settle_s=settle_s, vault_id=vault_id, browser_profile_id=browser_profile_id, use_default_browser_profile=use_default_browser_profile, persist_browser_profile=persist_browser_profile, network=network, + screenshot_max_width=screenshot_max_width, image=image, request_options=request_options, ) diff --git a/src/hai_agents/environments/raw_client.py b/src/hai_agents/environments/raw_client.py index 01dd6aa..77f8d0e 100644 --- a/src/hai_agents/environments/raw_client.py +++ b/src/hai_agents/environments/raw_client.py @@ -347,11 +347,13 @@ def patch_environment( session_id: typing.Optional[str] = OMIT, mode: typing.Optional[PatchEnvironmentMode] = OMIT, lazy: typing.Optional[bool] = OMIT, + settle_s: typing.Optional[float] = OMIT, vault_id: typing.Optional[str] = OMIT, browser_profile_id: typing.Optional[str] = OMIT, use_default_browser_profile: typing.Optional[bool] = OMIT, persist_browser_profile: typing.Optional[bool] = OMIT, network: typing.Optional[BrowserNetwork] = OMIT, + screenshot_max_width: typing.Optional[int] = OMIT, image: typing.Optional[str] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> HttpResponse[Environment]: @@ -374,6 +376,8 @@ def patch_environment( lazy : typing.Optional[bool] + settle_s : typing.Optional[float] + vault_id : typing.Optional[str] browser_profile_id : typing.Optional[str] @@ -384,6 +388,8 @@ def patch_environment( network : typing.Optional[BrowserNetwork] + screenshot_max_width : typing.Optional[int] + image : typing.Optional[str] request_options : typing.Optional[RequestOptions] @@ -406,6 +412,7 @@ def patch_environment( object_=mode, annotation=typing.Optional[PatchEnvironmentMode], direction="write" ), "lazy": lazy, + "settle_s": settle_s, "vault_id": vault_id, "browser_profile_id": browser_profile_id, "use_default_browser_profile": use_default_browser_profile, @@ -413,6 +420,7 @@ def patch_environment( "network": convert_and_respect_annotation_metadata( object_=network, annotation=typing.Optional[BrowserNetwork], direction="write" ), + "screenshot_max_width": screenshot_max_width, "image": image, }, headers={ @@ -771,11 +779,13 @@ async def patch_environment( session_id: typing.Optional[str] = OMIT, mode: typing.Optional[PatchEnvironmentMode] = OMIT, lazy: typing.Optional[bool] = OMIT, + settle_s: typing.Optional[float] = OMIT, vault_id: typing.Optional[str] = OMIT, browser_profile_id: typing.Optional[str] = OMIT, use_default_browser_profile: typing.Optional[bool] = OMIT, persist_browser_profile: typing.Optional[bool] = OMIT, network: typing.Optional[BrowserNetwork] = OMIT, + screenshot_max_width: typing.Optional[int] = OMIT, image: typing.Optional[str] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncHttpResponse[Environment]: @@ -798,6 +808,8 @@ async def patch_environment( lazy : typing.Optional[bool] + settle_s : typing.Optional[float] + vault_id : typing.Optional[str] browser_profile_id : typing.Optional[str] @@ -808,6 +820,8 @@ async def patch_environment( network : typing.Optional[BrowserNetwork] + screenshot_max_width : typing.Optional[int] + image : typing.Optional[str] request_options : typing.Optional[RequestOptions] @@ -830,6 +844,7 @@ async def patch_environment( object_=mode, annotation=typing.Optional[PatchEnvironmentMode], direction="write" ), "lazy": lazy, + "settle_s": settle_s, "vault_id": vault_id, "browser_profile_id": browser_profile_id, "use_default_browser_profile": use_default_browser_profile, @@ -837,6 +852,7 @@ async def patch_environment( "network": convert_and_respect_annotation_metadata( object_=network, annotation=typing.Optional[BrowserNetwork], direction="write" ), + "screenshot_max_width": screenshot_max_width, "image": image, }, headers={ diff --git a/src/hai_agents/environments/types/create_environment_request.py b/src/hai_agents/environments/types/create_environment_request.py index b4a084a..53cfec4 100644 --- a/src/hai_agents/environments/types/create_environment_request.py +++ b/src/hai_agents/environments/types/create_environment_request.py @@ -23,6 +23,7 @@ class CreateEnvironmentRequest_Web(UniversalBaseModel): session_id: typing.Optional[str] = None mode: typing.Optional[BrowserMode] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None vault_id: typing.Optional[str] = None browser_profile_id: typing.Optional[str] = None use_default_browser_profile: typing.Optional[bool] = None @@ -45,6 +46,8 @@ class CreateEnvironmentRequest_Desktop(UniversalBaseModel): host: DesktopHost session_id: typing.Optional[str] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None + screenshot_max_width: typing.Optional[int] = None if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 diff --git a/src/hai_agents/environments/types/update_environment_request_body.py b/src/hai_agents/environments/types/update_environment_request_body.py index 3bb0c0b..e8e6498 100644 --- a/src/hai_agents/environments/types/update_environment_request_body.py +++ b/src/hai_agents/environments/types/update_environment_request_body.py @@ -23,6 +23,7 @@ class UpdateEnvironmentRequestBody_Web(UniversalBaseModel): session_id: typing.Optional[str] = None mode: typing.Optional[BrowserMode] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None vault_id: typing.Optional[str] = None browser_profile_id: typing.Optional[str] = None use_default_browser_profile: typing.Optional[bool] = None @@ -45,6 +46,8 @@ class UpdateEnvironmentRequestBody_Desktop(UniversalBaseModel): host: DesktopHost session_id: typing.Optional[str] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None + screenshot_max_width: typing.Optional[int] = None if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 diff --git a/src/hai_agents/sessions/client.py b/src/hai_agents/sessions/client.py index 35c23f7..22b3089 100644 --- a/src/hai_agents/sessions/client.py +++ b/src/hai_agents/sessions/client.py @@ -174,10 +174,10 @@ def create_session( Seconds to keep the session open for follow-up messages after each answer. Null ends the session as soon as the agent answers. delete_after_min : typing.Optional[int] - Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever. + Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy. delete_screenshot_after_min : typing.Optional[int] - Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime. + Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier. queue : typing.Optional[bool] When the organization is at its concurrent-session limit, accept this session into a queue (status 'queued') instead of rejecting it with 429. Queued sessions start automatically, oldest first, as running sessions finish. Set to false to get an immediate 429 when no slot is available. @@ -961,10 +961,10 @@ async def create_session( Seconds to keep the session open for follow-up messages after each answer. Null ends the session as soon as the agent answers. delete_after_min : typing.Optional[int] - Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever. + Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy. delete_screenshot_after_min : typing.Optional[int] - Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime. + Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier. queue : typing.Optional[bool] When the organization is at its concurrent-session limit, accept this session into a queue (status 'queued') instead of rejecting it with 429. Queued sessions start automatically, oldest first, as running sessions finish. Set to false to get an immediate 429 when no slot is available. diff --git a/src/hai_agents/sessions/raw_client.py b/src/hai_agents/sessions/raw_client.py index e9b675c..ff91497 100644 --- a/src/hai_agents/sessions/raw_client.py +++ b/src/hai_agents/sessions/raw_client.py @@ -198,10 +198,10 @@ def create_session( Seconds to keep the session open for follow-up messages after each answer. Null ends the session as soon as the agent answers. delete_after_min : typing.Optional[int] - Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever. + Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy. delete_screenshot_after_min : typing.Optional[int] - Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime. + Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier. queue : typing.Optional[bool] When the organization is at its concurrent-session limit, accept this session into a queue (status 'queued') instead of rejecting it with 429. Queued sessions start automatically, oldest first, as running sessions finish. Set to false to get an immediate 429 when no slot is available. @@ -1325,10 +1325,10 @@ async def create_session( Seconds to keep the session open for follow-up messages after each answer. Null ends the session as soon as the agent answers. delete_after_min : typing.Optional[int] - Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever. + Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy. delete_screenshot_after_min : typing.Optional[int] - Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime. + Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier. queue : typing.Optional[bool] When the organization is at its concurrent-session limit, accept this session into a queue (status 'queued') instead of rejecting it with 429. Queued sessions start automatically, oldest first, as running sessions finish. Set to false to get an immediate 429 when no slot is available. diff --git a/src/hai_agents/skills/client.py b/src/hai_agents/skills/client.py index 8a64e54..3d606bb 100644 --- a/src/hai_agents/skills/client.py +++ b/src/hai_agents/skills/client.py @@ -88,6 +88,9 @@ def create_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -110,6 +113,12 @@ def create_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -137,6 +146,9 @@ def create_skill( body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data @@ -180,6 +192,9 @@ def update_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -204,6 +219,12 @@ def update_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -233,6 +254,9 @@ def update_skill( body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data @@ -274,6 +298,9 @@ def patch_skill( body: typing.Optional[str] = OMIT, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -291,6 +318,12 @@ def patch_skill( url_pattern : typing.Optional[str] + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, typing.Optional[str]]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -316,6 +349,9 @@ def patch_skill( body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data @@ -404,6 +440,9 @@ async def create_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -426,6 +465,12 @@ async def create_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -461,6 +506,9 @@ async def main() -> None: body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data @@ -512,6 +560,9 @@ async def update_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -536,6 +587,12 @@ async def update_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -573,6 +630,9 @@ async def main() -> None: body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data @@ -622,6 +682,9 @@ async def patch_skill( body: typing.Optional[str] = OMIT, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> Skill: """ @@ -639,6 +702,12 @@ async def patch_skill( url_pattern : typing.Optional[str] + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, typing.Optional[str]]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -672,6 +741,9 @@ async def main() -> None: body=body, source=source, url_pattern=url_pattern, + compatibility=compatibility, + files=files, + executable_files=executable_files, request_options=request_options, ) return _response.data diff --git a/src/hai_agents/skills/raw_client.py b/src/hai_agents/skills/raw_client.py index 63735e2..6808320 100644 --- a/src/hai_agents/skills/raw_client.py +++ b/src/hai_agents/skills/raw_client.py @@ -113,6 +113,9 @@ def create_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> HttpResponse[Skill]: """ @@ -135,6 +138,12 @@ def create_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -152,6 +161,9 @@ def create_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", @@ -249,6 +261,9 @@ def update_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> HttpResponse[Skill]: """ @@ -273,6 +288,12 @@ def update_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -290,6 +311,9 @@ def update_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", @@ -378,6 +402,9 @@ def patch_skill( body: typing.Optional[str] = OMIT, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> HttpResponse[Skill]: """ @@ -395,6 +422,12 @@ def patch_skill( url_pattern : typing.Optional[str] + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, typing.Optional[str]]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -411,6 +444,9 @@ def patch_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", @@ -541,6 +577,9 @@ async def create_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncHttpResponse[Skill]: """ @@ -563,6 +602,12 @@ async def create_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -580,6 +625,9 @@ async def create_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", @@ -679,6 +727,9 @@ async def update_skill( body: str, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, str]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncHttpResponse[Skill]: """ @@ -703,6 +754,12 @@ async def update_skill( url_pattern : typing.Optional[str] Optional regex hinting at URLs where this skill applies. + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, str]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -720,6 +777,9 @@ async def update_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", @@ -810,6 +870,9 @@ async def patch_skill( body: typing.Optional[str] = OMIT, source: typing.Optional[str] = OMIT, url_pattern: typing.Optional[str] = OMIT, + compatibility: typing.Optional[str] = OMIT, + files: typing.Optional[typing.Dict[str, typing.Optional[str]]] = OMIT, + executable_files: typing.Optional[typing.Sequence[str]] = OMIT, request_options: typing.Optional[RequestOptions] = None, ) -> AsyncHttpResponse[Skill]: """ @@ -827,6 +890,12 @@ async def patch_skill( url_pattern : typing.Optional[str] + compatibility : typing.Optional[str] + + files : typing.Optional[typing.Dict[str, typing.Optional[str]]] + + executable_files : typing.Optional[typing.Sequence[str]] + request_options : typing.Optional[RequestOptions] Request-specific configuration. @@ -843,6 +912,9 @@ async def patch_skill( "body": body, "source": source, "url_pattern": url_pattern, + "compatibility": compatibility, + "files": files, + "executable_files": executable_files, }, headers={ "content-type": "application/json", diff --git a/src/hai_agents/types/browser.py b/src/hai_agents/types/browser.py index db78441..3f1f050 100644 --- a/src/hai_agents/types/browser.py +++ b/src/hai_agents/types/browser.py @@ -49,6 +49,11 @@ class Browser(UniversalBaseModel): Provision on the agent's first use instead of at startup. Skips the initial observation. """ + settle_s: typing.Optional[float] = pydantic.Field(default=None) + """ + Seconds to wait after each page action. + """ + vault_id: typing.Optional[str] = pydantic.Field(default=None) """ Id of a vault config to bind to this browser, letting the agent sign in to sites with secrets resolved from the vault. The vault must belong to the caller's organization. Only supported on cloud-hosted browsers. Omit to run without secret access. diff --git a/src/hai_agents/types/desktop.py b/src/hai_agents/types/desktop.py index ad85554..04d2440 100644 --- a/src/hai_agents/types/desktop.py +++ b/src/hai_agents/types/desktop.py @@ -32,6 +32,16 @@ class Desktop(UniversalBaseModel): Provision on the agent's first use instead of at startup. Skips the initial observation. """ + settle_s: typing.Optional[float] = pydantic.Field(default=None) + """ + Seconds to wait after each input action. + """ + + screenshot_max_width: typing.Optional[int] = pydantic.Field(default=None) + """ + Maximum screenshot width in pixels. Null uses the host default; images are never upscaled. + """ + if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/hai_agents/types/environment.py b/src/hai_agents/types/environment.py index 1c58bd8..5c514c8 100644 --- a/src/hai_agents/types/environment.py +++ b/src/hai_agents/types/environment.py @@ -37,6 +37,8 @@ class Environment_Desktop(UniversalBaseModel): host: DesktopHost session_id: typing.Optional[str] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None + screenshot_max_width: typing.Optional[int] = None if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 @@ -57,6 +59,7 @@ class Environment_Web(UniversalBaseModel): session_id: typing.Optional[str] = None mode: typing.Optional[BrowserMode] = None lazy: typing.Optional[bool] = None + settle_s: typing.Optional[float] = None vault_id: typing.Optional[str] = None browser_profile_id: typing.Optional[str] = None use_default_browser_profile: typing.Optional[bool] = None diff --git a/src/hai_agents/types/session_request.py b/src/hai_agents/types/session_request.py index bec997a..6f2f4df 100644 --- a/src/hai_agents/types/session_request.py +++ b/src/hai_agents/types/session_request.py @@ -42,12 +42,12 @@ class SessionRequest(UniversalBaseModel): delete_after_min: typing.Optional[int] = pydantic.Field(default=None) """ - Minutes after the session finishes before it is automatically deleted. Defaults to 30 days. Null keeps the session forever. + Minutes after the session finishes before it is automatically deleted. When omitted, Portal's retention preference applies. An explicit value adds an earlier expiry; null adds no expiry beyond Portal's policy. """ delete_screenshot_after_min: typing.Optional[int] = pydantic.Field(default=None) """ - Minutes after the session finishes before its screenshots are deleted. Defaults to 30 days. Null keeps screenshots for the session's lifetime. + Minutes after the session finishes before its screenshots are deleted. When omitted or null, screenshots follow the session's retention policy. An explicit value can delete screenshots earlier. """ queue: typing.Optional[bool] = pydantic.Field(default=None) diff --git a/src/hai_agents/types/skill.py b/src/hai_agents/types/skill.py index 9a13ec6..2f72b6c 100644 --- a/src/hai_agents/types/skill.py +++ b/src/hai_agents/types/skill.py @@ -8,7 +8,7 @@ class Skill(UniversalBaseModel): """ - A named, reusable instruction an agent can draw on during a session. + Named instructions with optional scripts, references, and assets. """ name: str = pydantic.Field() @@ -36,6 +36,10 @@ class Skill(UniversalBaseModel): Optional regex hinting at URLs where this skill applies. """ + compatibility: typing.Optional[str] = None + files: typing.Optional[typing.Dict[str, str]] = None + executable_files: typing.Optional[typing.List[str]] = None + if IS_PYDANTIC_V2: model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2 else: diff --git a/src/hai_agents/types/workstation.py b/src/hai_agents/types/workstation.py index c1345a5..fd52bc3 100644 --- a/src/hai_agents/types/workstation.py +++ b/src/hai_agents/types/workstation.py @@ -29,7 +29,7 @@ class Workstation(UniversalBaseModel): lazy: typing.Optional[bool] = pydantic.Field(default=None) """ - Provision on the agent's first use instead of at startup. Cloud workstations only. + Start on the agent's first use instead of at startup. Skips the initial observation. A cloud workstation is provisioned on first use; a user_device one is not probed until then. """ if IS_PYDANTIC_V2: diff --git a/uv.lock b/uv.lock index 0f3079f..a6a109a 100644 --- a/uv.lock +++ b/uv.lock @@ -541,7 +541,7 @@ wheels = [ [[package]] name = "hai-agents" -version = "1.2.4" +version = "1.2.5" source = { editable = "." } dependencies = [ { name = "httpx" },