Commit fb4a994
fix(client): Handle 'data' key in paginate_all for get_all parameter
The paginate_all method was only checking for "results" key in API
responses, but some GitGuardian API endpoints return data using a
"data" key instead. This caused get_all=True to fail by returning
empty lists.
Added support for both response formats:
- {"results": [...]} (existing)
- {"data": [...]} (newly added)
This fixes MCP tool calls with get_all=True parameter for endpoints
like list_repo_incidents, list_repo_occurrences, and remediate_secret_incidents.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>1 parent 942009b commit fb4a994
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
567 | 567 | | |
568 | 568 | | |
569 | 569 | | |
| 570 | + | |
| 571 | + | |
570 | 572 | | |
571 | 573 | | |
572 | 574 | | |
| |||
0 commit comments