What problem does it solve?
When building distributed agent systems on Golem, one agent often needs to invoke another agent and wait for its result. This Skill explains how to use the auto-generated client types from the #[agent_definition] macro to perform blocking agent-to-agent RPC calls in Rust, including cross-component communication and deadlock avoidance.
Core Features & Use Cases
- Generated Client Types: Obtain a
<AgentName>Client via Client::get(...) using the target agent's constructor parameters, without explicitly creating the agent.
- Awaited RPC Calls: Call methods on the client and await results, blocking the calling agent until the target responds.
- Cross-Component RPC: Call agents defined in other components after
golem build generates bridge SDK code from dependencies declared in golem.yaml.
- Use Case: A coordinator agent needs the current count from a counter agent. It calls
CounterAgentClient::get("my-counter".to_string()) and then awaits counter.get_count() to retrieve the value synchronously.
Quick Start
Show me how to call another Golem agent from my Rust agent and await its result using the generated client.