Service Composition (Workflow-to-Workflow Calls)

How one workflow can invoke another via Execute Workflow node, with independent billing for each

Written By pvdyck

Last updated About 3 hours ago

Service Composition (Workflow-to-Workflow Calls)

Service composition allows one workflow (caller) to invoke another workflow (callee) through the Execute Workflow node. This enables modular design and reusable workflow components.

The Concept:

Caller Workflow:

  1. Step 1
  2. Execute Workflow Node β†’ triggers Callee
  3. Step 3

Callee Workflow:

  1. Trigger Node (receives call)
  2. Step A

Both workflows are billed independently.

What Is Service Composition?

Instead of building one giant workflow, you can break your automation into smaller, reusable pieces:

TypeDescription
πŸ“ž CallerUses Execute Workflow node to trigger other workflows
πŸ“ž CalleeStandalone workflow that can be invoked independently

This is the technical foundation of "agents calling agents."

How It Works

The Flow

StepWhat happens
1.Caller executes and reaches Execute Workflow node
2.System resolves callee via webhook registry
3.Callee executes its full workflow independently
4.Results return to caller
5.Both workflows are billed independently

Webhook Registry

The system maintains a reverse index to resolve callees:

Registry Key: instance:{chainId}:{address}:{tokenId}Registry Value: Webhook path for ExecuteWorkflowTrigger

When a workflow registers its webhook URL, it's stored for later lookup by other workflows.

Callee Requirements

For a workflow to be callable:

RequirementDescription
1.Use ExecuteWorkflowTrigger as entry point (not regular triggers)
2.Be deployed with registered webhook URL
3.Have active credentials for required services

Billing Model

Both workflows are billed independently:

WorkflowWhat You PayCovers
CallerExecute Workflow node executionCPU time, overhead for the call
CalleeFull workflow executionAll nodes, API calls, resources

Billing Example:

  • Caller: $0.01 (Execute Workflow node overhead)
  • Callee: $0.15 (full workflow execution)
  • Total: $0.16 (billed separately to respective owners)

Related