feat: expose output bindings over rpc

This commit is contained in:
lda
2026-07-23 03:34:37 +07:00 Verified
parent 418719e3c6
commit 56dddd6a31
6 changed files with 158 additions and 4 deletions
@@ -33,6 +33,7 @@ from ..models import (
SetDraftStartParams,
SetStepInputBindingsParams,
SetStepInputMapParams,
SetStepOutputBindingsParams,
SetStepOutputMapParams,
SetWorkflowOutputMapParams,
ValidateDraftParams,
@@ -244,6 +245,23 @@ def register_methods(
except (ValueError, KeyError, LookupError, FileNotFoundError) as exc:
raise_workflow_rpc_error(exc)
@entrypoint.method(
name="workflow.draft_workspaces.set_step_output_bindings",
errors=[WorkflowRpcError],
)
async def workflow_draft_workspaces_set_step_output_bindings(
params: SetStepOutputBindingsParams = RpcParams(),
) -> dict[str, Any]:
try:
return await server.api.set_step_output_bindings(
workspace_id=params.workspace_id,
revision=params.revision,
step_id=params.step_id,
bindings=params.bindings,
)
except (ValueError, KeyError, LookupError, FileNotFoundError) as exc:
raise_workflow_rpc_error(exc)
@entrypoint.method(
name="workflow.draft_workspaces.set_step_output_map",
errors=[WorkflowRpcError],