-
Notifications
You must be signed in to change notification settings - Fork 960
fix(mcp): stop classifying devices as offline in list_devices #3299
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -161,12 +161,10 @@ const listTaskStatusesOutput = z.object({ | |||||||||||||||||||||||||
| These tools write to `agent_commands` table and poll for results. | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| #### `list_devices` | ||||||||||||||||||||||||||
| List online devices in the organization. | ||||||||||||||||||||||||||
| List registered devices in the organization. | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ```typescript | ||||||||||||||||||||||||||
| const listDevicesInput = z.object({ | ||||||||||||||||||||||||||
| includeOffline: z.boolean().default(false).describe("Include recently offline devices"), | ||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||
| const listDevicesInput = z.object({}); | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| const listDevicesOutput = z.object({ | ||||||||||||||||||||||||||
| devices: z.array(z.object({ | ||||||||||||||||||||||||||
|
|
@@ -176,7 +174,6 @@ const listDevicesOutput = z.object({ | |||||||||||||||||||||||||
| ownerId: z.string().uuid().describe("User who owns this device"), | ||||||||||||||||||||||||||
| ownerName: z.string().describe("Name of device owner"), | ||||||||||||||||||||||||||
| lastSeenAt: z.string().datetime(), | ||||||||||||||||||||||||||
| isOnline: z.boolean(), | ||||||||||||||||||||||||||
| })), | ||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||
| ``` | ||||||||||||||||||||||||||
|
Comment on lines
168
to
179
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
The schema documented here no longer matches the actual Zod schema in
The PR description says this file was refreshed, but the schema block was not updated to match.
Suggested change
|
||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P2:
listDevicesOutputschema in MCP_TOOLS.md is still out of sync with the implementation after this refresh:deviceNameandownerNameshould be.nullable(), andownerEmail: z.string()is missing entirely. The implementation inlist-devices.tsand the type annotation inrun-agent.tsboth confirm these three differences.Prompt for AI agents