Overview
The III SDK provides methods to invoke functions synchronously (awaiting a response) or asynchronously (fire-and-forget).Synchronous Invocation
call
Invoke a function and await the response.str
required
The function ID to invoke
Any
required
Data to pass to the function (typically a dict)
float
Timeout in seconds. Raises
TimeoutError if exceededAny
The function’s return value
Error Handling
Exceptions from the remote function are propagated to the caller:Timeout Errors
Custom Timeout
Override the default timeout on a per-call basis:Asynchronous Invocation
call_void
Invoke a function without waiting for a response (fire-and-forget).str
required
The function ID to invoke
Any
required
Data to pass to the function
Use Cases
call_void is ideal for:
- Notifications: Sending emails, SMS, push notifications
- Logging: Fire-and-forget audit logs
- Background tasks: Queue jobs that don’t need immediate results
- Event broadcasting: Notify multiple subscribers
Aliases
trigger
Alias forcall(). Both methods are equivalent:
trigger_void
Alias forcall_void(). Both methods are equivalent:
Distributed Tracing
The SDK automatically propagates OpenTelemetry trace context across function calls when OTel is initialized:traceparent and baggage).
Channel References
The SDK automatically resolvesStreamChannelRef objects into ChannelReader or ChannelWriter instances: