Commit 31881cb
fix: use explicit skill invocation for A2A tool calls
Implement explicit skill invocation (deterministic) by default for A2A
protocol, as recommended by the A2A specification. This uses DataPart
with skill name and parameters instead of natural language interpretation.
**Changes:**
- Add `use_explicit_skill` parameter to `_call_a2a_tool` (default: True)
- Explicit mode: Send DataPart with `{"skill": "...", "parameters": {...}}`
- Natural language mode: Send TextPart with formatted text (legacy)
- Import DataPart from a2a.types
**Benefits:**
- Works without authentication for discovery endpoints (test agent)
- Predictable, repeatable behavior
- Direct skill execution without AI interpretation overhead
- Aligns with A2A best practices
**Reference:**
https://docs.adcontextprotocol.org/docs/protocols/a2a-guide
**Testing:**
- ✅ list_authorized_properties works without auth
- ✅ list_creative_formats works without auth
- ✅ get_products validates parameters correctly
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 5cd7e0e commit 31881cb
1 file changed
+49
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
13 | 22 | | |
14 | 23 | | |
15 | 24 | | |
| |||
115 | 124 | | |
116 | 125 | | |
117 | 126 | | |
118 | | - | |
119 | | - | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
120 | 142 | | |
121 | 143 | | |
122 | 144 | | |
123 | 145 | | |
124 | 146 | | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
131 | 171 | | |
132 | 172 | | |
133 | 173 | | |
| |||
0 commit comments