diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..6b52c0f --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1 @@ +# Stagehand Python Changelog diff --git a/CHANGELOG.txt b/CHANGELOG.txt deleted file mode 100644 index b5269eb..0000000 --- a/CHANGELOG.txt +++ /dev/null @@ -1,10 +0,0 @@ -# Stagehand Python SDK Changelog - -## 0.3.4 (2025-04-05) -- Fixed AgentExecuteResult schema - -## 0.3.3 (2025-04-04) -- Fixed logs - -## 0.3.0 -- Initial public release \ No newline at end of file diff --git a/stagehand/api.py b/stagehand/api.py index ff8601c..28eb216 100644 --- a/stagehand/api.py +++ b/stagehand/api.py @@ -1,4 +1,5 @@ import json +from datetime import datetime from typing import Any from .utils import convert_dict_keys_to_camel_case @@ -67,6 +68,7 @@ async def _create_session(self): "x-bb-project-id": self.browserbase_project_id, "x-model-api-key": self.model_api_key, "Content-Type": "application/json", + "x-sent-at": datetime.now().isoformat(), "x-language": "python", } @@ -96,6 +98,7 @@ async def _execute(self, method: str, payload: dict[str, Any]) -> Any: "x-bb-project-id": self.browserbase_project_id, "Content-Type": "application/json", "Connection": "keep-alive", + "x-sent-at": datetime.now().isoformat(), # Always enable streaming for better log handling "x-stream-response": "true", }