-
Notifications
You must be signed in to change notification settings - Fork 186
Description
Problem Statement
The A2AClientToolProvider for Strands currently lacks real-time notification capabilities when agent tasks complete. Users have no way to receive immediate feedback about task completion, requiring them to poll for results or implement custom monitoring solutions.
Proposed Solution
Add optional push notification capabilities to the A2AClientToolProvider to enable real-time webhook notifications when agent tasks complete.
Webhook Integration
- Add
webhook_urlandwebhook_tokenparameters to A2AClientToolProvider constructor - Automatically configure PushNotificationConfig when parameters are provided
- Include push notification configs in ClientFactory configuration
Use Case
Primary Use Cases:
- Long-running Tasks: Customers with agents performing complex operations that take minutes or hours need immediate notification when tasks complete
- Real-time Monitoring: Development teams need to monitor agent performance and task completion in real-time
- Workflow Integration: Customers integrating A2A agents into larger workflows need to trigger downstream processes immediately upon task completion
- Audit and Logging: Organizations need real-time task completion data for compliance and monitoring systems
Specific Scenarios:
- A customer service platform where completed agent conversations trigger immediate follow-up actions
- A data processing pipeline where agent task completion triggers the next stage of processing
- A monitoring dashboard that displays real-time agent activity and completion rates
Alternatives Solutions
- Custom Client Implementation: Users could extend the A2A client themselves, but this requires deep knowledge of the A2A protocol
- External Monitoring: Users could monitor A2A server logs or metrics, but this doesn't provide task-specific completion data
Additional Context
The solution should maintain full backward compatibility with existing A2AClientToolProvider usage. When webhook parameters are not provided, the behavior should remain unchanged. The webhook notifications should include complete task data including conversation history, final responses, and task status to enable comprehensive downstream processing.
This feature would complement the existing A2A server push notification capabilities feat(a2a): configurable request handler by providing client-side configuration and management of webhook endpoints.