Automate browser based workflows with AI
Python aiapiautomationbrowserbrowser-automationcomputergptllmplaywrightpowerautomatepuppeteerpythonrpaseleniumvisionworkflow
openapi.json update for user agent & auto generated code update (#2079)
Shuchang Zheng0d6f8f4f4fce
diff --git a/fern/openapi/skyvern_openapi.json b/fern/openapi/skyvern_openapi.jsonindex a9c8ea6b5..eeec3c904 100644--- a/fern/openapi/skyvern_openapi.json+++ b/fern/openapi/skyvern_openapi.json@@ -2604,6 +2604,22 @@"title": "X-Api-Key"}},+ {+ "name": "x-user-agent",+ "in": "header",+ "required": false,+ "schema": {+ "anyOf": [+ {+ "type": "string"+ },+ {+ "type": "null"+ }+ ],+ "title": "X-User-Agent"+ }+ },{"name": "authorization","in": "header",@@ -2711,6 +2727,22 @@"title": "X-Max-Steps-Override"}},+ {+ "name": "x-user-agent",+ "in": "header",+ "required": false,+ "schema": {+ "anyOf": [+ {+ "type": "string"+ },+ {+ "type": "null"+ }+ ],+ "title": "X-User-Agent"+ }+ },{"name": "authorization","in": "header",diff --git a/skyvern/client/agent/client.py b/skyvern/client/agent/client.pyindex 91bcfd279..626ab33b2 100644--- a/skyvern/client/agent/client.py+++ b/skyvern/client/agent/client.py@@ -269,6 +269,7 @@ class AgentClient:self,*,prompt: str,+ user_agent: typing.Optional[str] = None,url: typing.Optional[str] = OMIT,title: typing.Optional[str] = OMIT,engine: typing.Optional[RunEngine] = OMIT,@@ -291,6 +292,8 @@ class AgentClient:prompt : strThe goal or task description for Skyvern to accomplish+ user_agent : typing.Optional[str]+url : typing.Optional[str]The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL@@ -367,6 +370,9 @@ class AgentClient:"browser_session_id": browser_session_id,"publish_workflow": publish_workflow,},+ headers={+ "x-user-agent": str(user_agent) if user_agent is not None else None,+ },request_options=request_options,omit=OMIT,)@@ -410,6 +416,7 @@ class AgentClient:workflow_id: str,template: typing.Optional[bool] = None,max_steps_override: typing.Optional[int] = None,+ user_agent: typing.Optional[str] = None,title: typing.Optional[str] = OMIT,parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,proxy_location: typing.Optional[ProxyLocation] = OMIT,@@ -431,6 +438,8 @@ class AgentClient:max_steps_override : typing.Optional[int]+ user_agent : typing.Optional[str]+title : typing.Optional[str]Optional title for this workflow run@@ -490,6 +499,7 @@ class AgentClient:},headers={"x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,+ "x-user-agent": str(user_agent) if user_agent is not None else None,},request_options=request_options,omit=OMIT,@@ -870,6 +880,7 @@ class AsyncAgentClient:self,*,prompt: str,+ user_agent: typing.Optional[str] = None,url: typing.Optional[str] = OMIT,title: typing.Optional[str] = OMIT,engine: typing.Optional[RunEngine] = OMIT,@@ -892,6 +903,8 @@ class AsyncAgentClient:prompt : strThe goal or task description for Skyvern to accomplish+ user_agent : typing.Optional[str]+url : typing.Optional[str]The starting URL for the task. If not provided, Skyvern will attempt to determine an appropriate URL@@ -976,6 +989,9 @@ class AsyncAgentClient:"browser_session_id": browser_session_id,"publish_workflow": publish_workflow,},+ headers={+ "x-user-agent": str(user_agent) if user_agent is not None else None,+ },request_options=request_options,omit=OMIT,)@@ -1019,6 +1035,7 @@ class AsyncAgentClient:workflow_id: str,template: typing.Optional[bool] = None,max_steps_override: typing.Optional[int] = None,+ user_agent: typing.Optional[str] = None,title: typing.Optional[str] = OMIT,parameters: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = OMIT,proxy_location: typing.Optional[ProxyLocation] = OMIT,@@ -1040,6 +1057,8 @@ class AsyncAgentClient:max_steps_override : typing.Optional[int]+ user_agent : typing.Optional[str]+title : typing.Optional[str]Optional title for this workflow run@@ -1107,6 +1126,7 @@ class AsyncAgentClient:},headers={"x-max-steps-override": str(max_steps_override) if max_steps_override is not None else None,+ "x-user-agent": str(user_agent) if user_agent is not None else None,},request_options=request_options,omit=OMIT,diff --git a/skyvern/client/core/client_wrapper.py b/skyvern/client/core/client_wrapper.pyindex 4ab5894bb..2fc86874a 100644--- a/skyvern/client/core/client_wrapper.py+++ b/skyvern/client/core/client_wrapper.py@@ -24,7 +24,7 @@ class BaseClientWrapper:headers: typing.Dict[str, str] = {"X-Fern-Language": "Python","X-Fern-SDK-Name": "skyvern",- "X-Fern-SDK-Version": "0.1.69",+ "X-Fern-SDK-Version": "0.1.70",}if self._api_key is not None:headers["x-api-key"] = self._api_key