Commit 2e2516f
feat: include node information in get and list command responses (#1100)
## Summary
Enhances both the `get` and `list` commands to include node information
in their JSON/YAML responses, allowing users to see which node was used
for retrieving the content.
**Before (get command):**
```json
{
"id": "sh7lxf0xxkyekj70632czg2c",
"content": "Call pediatrician for flu shot appointment",
"mimeType": "text/plain",
"byteSize": 42,
...
}
```
**After (get command):**
```json
{
"id": "sh7lxf0xxkyekj70632czg2c",
"node": "personal",
"content": "Call pediatrician for flu shot appointment",
"mimeType": "text/plain",
"byteSize": 42,
...
}
```
**Before (list command):**
```json
{
"items": [
{
"id": "sh7lxf0xxkyekj70632czg2c",
"content": "...",
...
}
],
"pagination": {...}
}
```
**After (list command):**
```json
{
"items": [
{
"id": "sh7lxf0xxkyekj70632czg2c",
"node": "personal",
"content": "...",
...
}
],
"pagination": {...}
}
```
## Changes
- Modified `GetCommand.cs` to wrap result with node information
- Modified `ListCommand.cs` to wrap each item with node information
- Node information is already available from the `Initialize()` method
- Maintains all existing fields in the response
## Testing
- ✅ All 301 tests pass (192 Main.Tests + 109 Core.Tests)
- ✅ 0 skipped tests
- ✅ Code coverage: 81.99% (exceeds 80% threshold)
- ✅ Build: 0 warnings, 0 errors
## Stats
- **Files changed:** 2
- **Lines added:** 36
- **Lines removed:** 2
- **Tests added:** 0 (existing tests validate behavior)
## Breaking Changes
None - this is a backward-compatible enhancement that adds information
to the response while maintaining all existing fields.
Co-authored-by: Amplifier <[email protected]>1 parent bdd7221 commit 2e2516f
2 files changed
+36
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
72 | 89 | | |
73 | 90 | | |
74 | | - | |
| 91 | + | |
75 | 92 | | |
76 | 93 | | |
77 | 94 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
77 | 94 | | |
78 | | - | |
| 95 | + | |
79 | 96 | | |
80 | 97 | | |
81 | 98 | | |
| |||
0 commit comments