Skip to content

Commit 785e52d

Browse files
committed
input is required
1 parent 58249a6 commit 785e52d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/cradl/client.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3310,19 +3310,19 @@ def get_action_run(self, action_id: str, run_id: str) -> Dict:
33103310
def create_action_run(
33113311
self,
33123312
action_id: str,
3313+
input: dict,
33133314
*,
33143315
agent_run_id: Optional[str] = None,
3315-
input: Optional[dict] = None,
33163316
metadata: Optional[dict] = None,
33173317
) -> Dict:
33183318
"""Create action run, calls the POST /actions/{actionId}/runs endpoint.
33193319
33203320
:param action_id: Id of the action
33213321
:type action_id: str
3322-
:param agent_run_id: Id of an agent run to associate with the action run
3323-
:type agent_run_id: str
33243322
:param input: Dictionary with input to the run
3325-
:type input: dict, optional
3323+
:type input: dict
3324+
:param agent_run_id: Id of an agent run to associate with the action run
3325+
:type agent_run_id: str, optional
33263326
:param metadata: Dictionary that can be used to store additional information
33273327
:type metadata: dict, optional
33283328
:return: Action response from REST API
@@ -3333,7 +3333,7 @@ def create_action_run(
33333333
"""
33343334
body = dictstrip({
33353335
'agentRunId': agent_run_id,
3336-
'input': input,
3336+
'input': input or {},
33373337
'metadata': metadata,
33383338
})
33393339
return self._make_request(requests.post, f'/actions/{action_id}/runs', body=body)

0 commit comments

Comments
 (0)