smooth-py 0.3.0.dev20251013__py3-none-any.whl → 0.3.0.dev20251014__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of smooth-py might be problematic. Click here for more details.

smooth/__init__.py CHANGED
@@ -486,7 +486,7 @@ class SmoothClient(BaseClient):
486
486
  response_model: If provided, the schema describing the desired output structure.
487
487
  url: The starting URL for the task. If not provided, the agent will infer it from the task.
488
488
  metadata: A dictionary containing variables or parameters that will be passed to the agent.
489
- files: A dictionary of file names to their ids. These files will be passed to the agent.
489
+ files: A list of file ids to pass to the agent.
490
490
  agent: The agent to use for the task.
491
491
  max_steps: Maximum number of steps the agent can take (max 64).
492
492
  device: Device type for the task. Default is mobile.
@@ -686,7 +686,7 @@ class AsyncTaskHandle:
686
686
  await asyncio.sleep(poll_interval)
687
687
  raise TimeoutError(f"Task {self.id()} did not complete within {timeout} seconds.")
688
688
 
689
- async def live_url(self, interactive: bool = True, embed: bool = False, timeout: int | None = None):
689
+ async def live_url(self, interactive: bool = False, embed: bool = False, timeout: int | None = None):
690
690
  """Returns the live URL for the task."""
691
691
  if self._task_response and self._task_response.live_url:
692
692
  return _encode_url(self._task_response.live_url, interactive=interactive, embed=embed)
@@ -695,13 +695,13 @@ class AsyncTaskHandle:
695
695
  while timeout is None or (time.time() - start_time) < timeout:
696
696
  task_response = await self._client._get_task(self.id())
697
697
  self._task_response = task_response
698
- if task_response.live_url is not None:
699
- return _encode_url(task_response.live_url, interactive=interactive, embed=embed)
698
+ if self._task_response.live_url:
699
+ return _encode_url(self._task_response.live_url, interactive=interactive, embed=embed)
700
700
  await asyncio.sleep(1)
701
701
 
702
702
  raise TimeoutError(f"Live URL not available for task {self.id()}.")
703
703
 
704
- async def recording_url(self, timeout: int | None = None):
704
+ async def recording_url(self, timeout: int | None = None) -> str:
705
705
  """Returns the recording URL for the task."""
706
706
  if self._task_response and self._task_response.recording_url is not None:
707
707
  return self._task_response.recording_url
@@ -799,7 +799,7 @@ class SmoothAsyncClient(BaseClient):
799
799
  response_model: If provided, the schema describing the desired output structure.
800
800
  url: The starting URL for the task. If not provided, the agent will infer it from the task.
801
801
  metadata: A dictionary containing variables or parameters that will be passed to the agent.
802
- files: A dictionary of file names to their url or base64-encoded content to be used by the agent.
802
+ files: A list of file ids to pass to the agent.
803
803
  agent: The agent to use for the task.
804
804
  max_steps: Maximum number of steps the agent can take (max 64).
805
805
  device: Device type for the task. Default is mobile.
@@ -850,8 +850,8 @@ class SmoothAsyncClient(BaseClient):
850
850
  """Opens an interactive browser instance asynchronously.
851
851
 
852
852
  Args:
853
+ profile_id: The profile ID to use for the session. If None, a new profile will be created.
853
854
  session_id: (Deprecated, now `profile_id`) The session ID to associate with the browser.
854
- profile_id: The profile ID to associate with the browser.
855
855
  live_view: Whether to enable live view for the session.
856
856
 
857
857
  Returns:
@@ -936,11 +936,12 @@ class SmoothAsyncClient(BaseClient):
936
936
  if name is None:
937
937
  raise ValueError("File name must be provided or the file object must have a 'name' attribute.")
938
938
 
939
- files = {"file": (Path(name).name, file)}
940
939
  if purpose:
941
940
  data = {"file_purpose": purpose}
942
941
  else:
943
942
  data = None
943
+
944
+ files = {"file": (Path(name).name, file)}
944
945
  response = await self._client.post(f"{self.base_url}/file", files=files, data=data)
945
946
  data = self._handle_response(response)
946
947
  return UploadFileResponse(**data["r"])
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: smooth-py
3
- Version: 0.3.0.dev20251013
3
+ Version: 0.3.0.dev20251014
4
4
  Summary:
5
5
  Author: Luca Pinchetti
6
6
  Author-email: luca@circlemind.co
@@ -0,0 +1,6 @@
1
+ smooth/__init__.py,sha256=yhlG6m00uOw8umRC7ONImCMCiCkWTV5khj050qfD_V8,38411
2
+ smooth/mcp/__init__.py,sha256=0aJVFi2a8Ah3-5xtgyZ5UMbaaJsBWu2T8QLWoFQITk8,219
3
+ smooth/mcp/server.py,sha256=9SymTD4NOGTMN8P-LNGlvYNvv81yCIZfZeeuhEcAc6s,20068
4
+ smooth_py-0.3.0.dev20251014.dist-info/METADATA,sha256=Ef7Ys-PREpnYOCtk6XuQRlzWwh-adFP0FxU8jMOHCGM,7529
5
+ smooth_py-0.3.0.dev20251014.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
6
+ smooth_py-0.3.0.dev20251014.dist-info/RECORD,,
@@ -1,6 +0,0 @@
1
- smooth/__init__.py,sha256=8cuQGi1QbHBbW0dcM9ZyyZL-PrMmAoR3LmLZcqksdJA,38460
2
- smooth/mcp/__init__.py,sha256=0aJVFi2a8Ah3-5xtgyZ5UMbaaJsBWu2T8QLWoFQITk8,219
3
- smooth/mcp/server.py,sha256=9SymTD4NOGTMN8P-LNGlvYNvv81yCIZfZeeuhEcAc6s,20068
4
- smooth_py-0.3.0.dev20251013.dist-info/METADATA,sha256=CJIChVHrQ4YqTk7TioEH-u_4ecw9OurNAw1KAOf3Q1w,7529
5
- smooth_py-0.3.0.dev20251013.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
6
- smooth_py-0.3.0.dev20251013.dist-info/RECORD,,