@cyanheads/pixoo-mcp-server 1.1.3 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +19 -13
- package/CLAUDE.md +19 -13
- package/README.md +16 -14
- package/changelog/1.1.x/1.1.4.md +22 -0
- package/changelog/1.2.x/1.2.0.md +28 -0
- package/dist/mcp-server/resources/definitions/pixoo-design-guide.resource.d.ts.map +1 -1
- package/dist/mcp-server/resources/definitions/pixoo-design-guide.resource.js +1 -0
- package/dist/mcp-server/resources/definitions/pixoo-design-guide.resource.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-compose-scene.tool.d.ts +6 -0
- package/dist/mcp-server/tools/definitions/pixoo-compose-scene.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-compose-scene.tool.js +32 -41
- package/dist/mcp-server/tools/definitions/pixoo-compose-scene.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-control-device.tool.d.ts +3 -1
- package/dist/mcp-server/tools/definitions/pixoo-control-device.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-control-device.tool.js +20 -20
- package/dist/mcp-server/tools/definitions/pixoo-control-device.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-design-brief.tool.d.ts +3 -3
- package/dist/mcp-server/tools/definitions/pixoo-design-brief.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-design-brief.tool.js +56 -44
- package/dist/mcp-server/tools/definitions/pixoo-design-brief.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-display-text.tool.d.ts +7 -0
- package/dist/mcp-server/tools/definitions/pixoo-display-text.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-display-text.tool.js +128 -32
- package/dist/mcp-server/tools/definitions/pixoo-display-text.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-overlay-text.tool.d.ts +5 -0
- package/dist/mcp-server/tools/definitions/pixoo-overlay-text.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-overlay-text.tool.js +38 -13
- package/dist/mcp-server/tools/definitions/pixoo-overlay-text.tool.js.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-push-image.tool.d.ts +6 -0
- package/dist/mcp-server/tools/definitions/pixoo-push-image.tool.d.ts.map +1 -1
- package/dist/mcp-server/tools/definitions/pixoo-push-image.tool.js +16 -8
- package/dist/mcp-server/tools/definitions/pixoo-push-image.tool.js.map +1 -1
- package/dist/mcp-server/tools/device-push.d.ts +24 -0
- package/dist/mcp-server/tools/device-push.d.ts.map +1 -0
- package/dist/mcp-server/tools/device-push.js +50 -0
- package/dist/mcp-server/tools/device-push.js.map +1 -0
- package/dist/renderer/preview.d.ts +17 -19
- package/dist/renderer/preview.d.ts.map +1 -1
- package/dist/renderer/preview.js +55 -34
- package/dist/renderer/preview.js.map +1 -1
- package/dist/renderer/remote-image.d.ts +6 -2
- package/dist/renderer/remote-image.d.ts.map +1 -1
- package/dist/renderer/remote-image.js +31 -7
- package/dist/renderer/remote-image.js.map +1 -1
- package/dist/renderer/scene-renderer.d.ts +14 -9
- package/dist/renderer/scene-renderer.d.ts.map +1 -1
- package/dist/renderer/scene-renderer.js +51 -30
- package/dist/renderer/scene-renderer.js.map +1 -1
- package/dist/renderer/text-engine.d.ts +14 -1
- package/dist/renderer/text-engine.d.ts.map +1 -1
- package/dist/renderer/text-engine.js +22 -4
- package/dist/renderer/text-engine.js.map +1 -1
- package/dist/services/pixoo/pixoo-service.d.ts +14 -1
- package/dist/services/pixoo/pixoo-service.d.ts.map +1 -1
- package/dist/services/pixoo/pixoo-service.js +39 -16
- package/dist/services/pixoo/pixoo-service.js.map +1 -1
- package/package.json +1 -1
- package/server.json +3 -3
|
@@ -51,6 +51,12 @@ export const pixooControlDevice = tool('pixoo_control_device', {
|
|
|
51
51
|
.array(z.string())
|
|
52
52
|
.describe('Settings successfully applied in this call (e.g. "brightness:80", "screen:on"). Empty when called with no params or all changes failed. A requested setting that failed is absent here and reported in a notice instead.'),
|
|
53
53
|
}),
|
|
54
|
+
enrichment: {
|
|
55
|
+
notice: z
|
|
56
|
+
.string()
|
|
57
|
+
.optional()
|
|
58
|
+
.describe('Requested settings that failed, each with its failure kind and message (e.g. "brightness:80 failed (network): …"), joined by "; ". Absent when every requested setting applied.'),
|
|
59
|
+
},
|
|
54
60
|
errors: [
|
|
55
61
|
{
|
|
56
62
|
reason: 'no_device_configured',
|
|
@@ -63,35 +69,29 @@ export const pixooControlDevice = tool('pixoo_control_device', {
|
|
|
63
69
|
async handler(input, ctx) {
|
|
64
70
|
const svc = getPixooService();
|
|
65
71
|
const applied = [];
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
const res = await svc.setBrightness(input.brightness, ctx);
|
|
72
|
+
const failed = [];
|
|
73
|
+
const record = (setting, res) => {
|
|
69
74
|
if (res.ok)
|
|
70
|
-
applied.push(
|
|
75
|
+
applied.push(setting);
|
|
71
76
|
else
|
|
72
|
-
|
|
77
|
+
failed.push(`${setting} failed (${res.kind}): ${res.message}`);
|
|
78
|
+
};
|
|
79
|
+
// Apply changes
|
|
80
|
+
if (input.brightness !== undefined) {
|
|
81
|
+
record(`brightness:${input.brightness}`, await svc.setBrightness(input.brightness, ctx));
|
|
73
82
|
}
|
|
74
83
|
if (input.screen !== undefined) {
|
|
75
|
-
|
|
76
|
-
if (res.ok)
|
|
77
|
-
applied.push(`screen:${input.screen}`);
|
|
78
|
-
else
|
|
79
|
-
ctx.enrich.notice(`screen:${input.screen} failed (${res.kind}): ${res.message}`);
|
|
84
|
+
record(`screen:${input.screen}`, await svc.setScreen(input.screen === 'on', ctx));
|
|
80
85
|
}
|
|
81
86
|
if (input.channel) {
|
|
82
|
-
|
|
83
|
-
if (res.ok)
|
|
84
|
-
applied.push(`channel:${input.channel}`);
|
|
85
|
-
else
|
|
86
|
-
ctx.enrich.notice(`channel:${input.channel} failed (${res.kind}): ${res.message}`);
|
|
87
|
+
record(`channel:${input.channel}`, await svc.setChannel(input.channel, ctx));
|
|
87
88
|
}
|
|
88
89
|
if (input.clockFaceId !== undefined) {
|
|
89
|
-
|
|
90
|
-
if (res.ok)
|
|
91
|
-
applied.push(`clockFace:${input.clockFaceId}`);
|
|
92
|
-
else
|
|
93
|
-
ctx.enrich.notice(`clockFace:${input.clockFaceId} failed (${res.kind}): ${res.message}`);
|
|
90
|
+
record(`clockFace:${input.clockFaceId}`, await svc.setClock(input.clockFaceId, ctx));
|
|
94
91
|
}
|
|
92
|
+
// ctx.enrich.notice is last-wins, so every failure goes out in one call.
|
|
93
|
+
if (failed.length > 0)
|
|
94
|
+
ctx.enrich.notice(failed.join('; '));
|
|
95
95
|
// Read current state
|
|
96
96
|
const state = await svc.getStatus(ctx);
|
|
97
97
|
return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pixoo-control-device.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-control-device.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"pixoo-control-device.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-control-device.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAEjE,OAAO,EAAE,eAAe,EAAE,MAAM,mCAAmC,CAAC;AAEpE,MAAM,CAAC,MAAM,kBAAkB,GAAG,IAAI,CAAC,sBAAsB,EAAE;IAC7D,KAAK,EAAE,sBAAsB;IAC7B,WAAW,EACT,2QAA2Q;IAC7Q,WAAW,EAAE,EAAE,cA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,CAAC,CAAC;QACpF,IAAI,MAAM,CAAC,QAAQ,KAAK,SAAS;YAAE,KAAK,CAAC,IAAI,CAAC,WAAW,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC;QAC3F,IAAI,MAAM,CAAC,OAAO,KAAK,SAAS;YAAE,KAAK,CAAC,IAAI,CAAC,eAAe,MAAM,CAAC,OAAO,EAAE,CAAC,CAAC;QAC9E,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;YAC9B,KAAK,CAAC,IAAI,CAAC,cAAc,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACxD,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -23,9 +23,9 @@ export declare const pixooDesignBrief: import("@cyanheads/mcp-ts-core").ToolDefi
|
|
|
23
23
|
screenOn: z.ZodOptional<z.ZodBoolean>;
|
|
24
24
|
}, z.core.$strip>;
|
|
25
25
|
nextToolSuggestions: z.ZodArray<z.ZodObject<{
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
26
|
+
toolName: z.ZodString;
|
|
27
|
+
reason: z.ZodString;
|
|
28
|
+
args: z.ZodObject<{}, z.core.$loose>;
|
|
29
29
|
}, z.core.$strip>>;
|
|
30
30
|
availableThemes: z.ZodArray<z.ZodString>;
|
|
31
31
|
iconCategories: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pixoo-design-brief.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-design-brief.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"pixoo-design-brief.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-design-brief.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AAgJjD,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;wCAyO3B,CAAC"}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import { tool, z } from '@cyanheads/mcp-ts-core';
|
|
6
6
|
import { getServerConfig } from '../../../config/server-config.js';
|
|
7
|
+
import { DIM_BRIGHTNESS } from '../device-push.js';
|
|
7
8
|
import { getIconsByCategory } from '../../../renderer/icons.js';
|
|
8
9
|
import { THEME_NAMES } from '../../../renderer/themes.js';
|
|
9
10
|
import { getPixooService } from '../../../services/pixoo/pixoo-service.js';
|
|
@@ -24,9 +25,11 @@ const CRAFT_CONTENT = {
|
|
|
24
25
|
|
|
25
26
|
**Shadow + outline:** Add \`shadow: true\` for dark backgrounds; \`outline: true\` for legibility against low-contrast backgrounds.
|
|
26
27
|
|
|
27
|
-
**Auto-fit:**
|
|
28
|
+
**Auto-fit:** Single-line text tries the standard font, then compact; set \`font\` to keep one font, and text too wide for it overflows instead of shrinking. Every fit decision appears in \`layout[]\`. Text still too wide shows only its opening characters — set \`effect: "auto"\` to scroll it across the display instead, or \`effect: "scroll"\` to scroll any text.
|
|
28
29
|
|
|
29
|
-
**
|
|
30
|
+
**Motion:** \`effect: "float"\` (gentle bob) or \`effect: "pulse"\` (breathing brightness) loops over 20 frames. Motion reads best on short headlines; keep long text static or scrolling.
|
|
31
|
+
|
|
32
|
+
**Multi-line stacking:** For 3 lines at scale 2: 10px + 1px gap × 3 = 33px. Leaves 15.5px margin above and below on a 64px canvas — plan your vertical budget. \`align: "left"\` or \`"right"\` lines up the edges of the lines; \`position.x\` places the block.`,
|
|
30
33
|
scene: `## Scene Composition Guidance
|
|
31
34
|
|
|
32
35
|
**Design system:** Every element renders back-to-front in array order. Background → fill elements → widgets → text headline → foreground details.
|
|
@@ -118,6 +121,21 @@ const CRAFT_CONTENT = {
|
|
|
118
121
|
- resolveColor throws on typos; check the error message for the accepted formats
|
|
119
122
|
- LEDs don't reproduce very dark colors (< #202020) well`,
|
|
120
123
|
};
|
|
124
|
+
/**
|
|
125
|
+
* A follow-up call with its arguments pre-filled — the `{ toolName, reason, args }`
|
|
126
|
+
* shape other suggestion-emitting servers use, declared here until the framework
|
|
127
|
+
* exports it (cyanheads/mcp-ts-core#478).
|
|
128
|
+
*/
|
|
129
|
+
const NextToolSuggestionSchema = z
|
|
130
|
+
.object({
|
|
131
|
+
toolName: z.string().describe('Tool to call next.'),
|
|
132
|
+
reason: z.string().describe('Why this step is recommended given the current device state.'),
|
|
133
|
+
args: z
|
|
134
|
+
.object({})
|
|
135
|
+
.passthrough()
|
|
136
|
+
.describe('Pre-filled arguments for the call; {} when the tool needs none.'),
|
|
137
|
+
})
|
|
138
|
+
.describe('A recommended follow-up call with its arguments pre-filled.');
|
|
121
139
|
export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
122
140
|
title: 'pixoo_design_brief',
|
|
123
141
|
description: 'Return craft guidance and live device context for a design topic. Covers legibility rules, palette discipline, layout zones, animation budget, and pre-filled next-tool suggestions based on current device state. The orientation tool to run before authoring a scene, dashboard, or animation — or when troubleshooting display issues.',
|
|
@@ -149,17 +167,7 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
149
167
|
})
|
|
150
168
|
.describe('Live device state snapshot at the time of the request.'),
|
|
151
169
|
nextToolSuggestions: z
|
|
152
|
-
.array(
|
|
153
|
-
.object({
|
|
154
|
-
tool: z.string().describe('Tool name to try next.'),
|
|
155
|
-
rationale: z.string().describe('Why this tool is relevant given current state.'),
|
|
156
|
-
suggestedArgs: z
|
|
157
|
-
.object({})
|
|
158
|
-
.passthrough()
|
|
159
|
-
.optional()
|
|
160
|
-
.describe('Pre-filled argument suggestions as a key-value object.'),
|
|
161
|
-
})
|
|
162
|
-
.describe('A suggested next-step tool with rationale and optional pre-filled args.'))
|
|
170
|
+
.array(NextToolSuggestionSchema)
|
|
163
171
|
.describe('Suggested next steps based on topic and device state.'),
|
|
164
172
|
availableThemes: z
|
|
165
173
|
.array(z.string())
|
|
@@ -181,9 +189,9 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
181
189
|
const suggestions = [];
|
|
182
190
|
if (input.topic === 'text') {
|
|
183
191
|
suggestions.push({
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
192
|
+
toolName: 'pixoo_display_text',
|
|
193
|
+
reason: 'The primary tool for styled text rendering.',
|
|
194
|
+
args: {
|
|
187
195
|
text: 'HELLO',
|
|
188
196
|
theme: 'midnight',
|
|
189
197
|
style: { palette: 'lavender', shadow: true, scale: 2 },
|
|
@@ -192,16 +200,17 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
192
200
|
});
|
|
193
201
|
if (!deviceStatus.reachable) {
|
|
194
202
|
suggestions.push({
|
|
195
|
-
|
|
196
|
-
|
|
203
|
+
toolName: 'pixoo_discover_devices',
|
|
204
|
+
reason: 'Device is not reachable — find it on the network first.',
|
|
205
|
+
args: {},
|
|
197
206
|
});
|
|
198
207
|
}
|
|
199
208
|
}
|
|
200
209
|
else if (input.topic === 'scene') {
|
|
201
210
|
suggestions.push({
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
211
|
+
toolName: 'pixoo_compose_scene',
|
|
212
|
+
reason: 'Full scene composition with layered elements.',
|
|
213
|
+
args: {
|
|
205
214
|
background: { theme: 'midnight' },
|
|
206
215
|
elements: [
|
|
207
216
|
{
|
|
@@ -219,9 +228,9 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
219
228
|
}
|
|
220
229
|
else if (input.topic === 'dashboard') {
|
|
221
230
|
suggestions.push({
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
231
|
+
toolName: 'pixoo_compose_scene',
|
|
232
|
+
reason: 'Compose a status dashboard with widgets.',
|
|
233
|
+
args: {
|
|
225
234
|
background: { gradient: { type: 'v', from: '#0a1020', to: '#000000' } },
|
|
226
235
|
elements: [
|
|
227
236
|
{ type: 'text', text: 'STATUS', x: 2, y: 2, style: { palette: 'ice' } },
|
|
@@ -235,9 +244,9 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
235
244
|
}
|
|
236
245
|
else if (input.topic === 'animation') {
|
|
237
246
|
suggestions.push({
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
247
|
+
toolName: 'pixoo_compose_scene',
|
|
248
|
+
reason: 'Compose an animated scene.',
|
|
249
|
+
args: {
|
|
241
250
|
background: { theme: 'midnight' },
|
|
242
251
|
elements: [
|
|
243
252
|
{
|
|
@@ -258,36 +267,39 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
258
267
|
else if (input.topic === 'troubleshooting') {
|
|
259
268
|
if (!deviceStatus.reachable) {
|
|
260
269
|
suggestions.push({
|
|
261
|
-
|
|
262
|
-
|
|
270
|
+
toolName: 'pixoo_discover_devices',
|
|
271
|
+
reason: 'Device is not reachable — discover it on the network.',
|
|
272
|
+
args: {},
|
|
263
273
|
});
|
|
264
274
|
}
|
|
265
275
|
else if (deviceStatus.screenOn === false) {
|
|
266
276
|
suggestions.push({
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
277
|
+
toolName: 'pixoo_control_device',
|
|
278
|
+
reason: 'Screen appears to be off.',
|
|
279
|
+
args: { screen: 'on' },
|
|
270
280
|
});
|
|
271
281
|
}
|
|
272
|
-
else if (deviceStatus.brightness !== undefined &&
|
|
282
|
+
else if (deviceStatus.brightness !== undefined &&
|
|
283
|
+
deviceStatus.brightness <= DIM_BRIGHTNESS) {
|
|
273
284
|
suggestions.push({
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
285
|
+
toolName: 'pixoo_control_device',
|
|
286
|
+
reason: 'Brightness is very low — content may not be visible.',
|
|
287
|
+
args: { brightness: 80 },
|
|
277
288
|
});
|
|
278
289
|
}
|
|
279
290
|
else {
|
|
280
291
|
suggestions.push({
|
|
281
|
-
|
|
282
|
-
|
|
292
|
+
toolName: 'pixoo_control_device',
|
|
293
|
+
reason: 'Read full device state.',
|
|
294
|
+
args: {},
|
|
283
295
|
});
|
|
284
296
|
}
|
|
285
297
|
}
|
|
286
298
|
else {
|
|
287
299
|
suggestions.push({
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
300
|
+
toolName: 'pixoo_display_text',
|
|
301
|
+
reason: 'Start with text display to verify the pipeline works end-to-end.',
|
|
302
|
+
args: { text: 'TEST', push: false },
|
|
291
303
|
});
|
|
292
304
|
}
|
|
293
305
|
const craftGuidance = CRAFT_CONTENT[input.topic] ?? 'No guidance available for this topic.';
|
|
@@ -323,10 +335,10 @@ export const pixooDesignBrief = tool('pixoo_design_brief', {
|
|
|
323
335
|
lines.push('');
|
|
324
336
|
lines.push('## Next Steps');
|
|
325
337
|
for (const s of result.nextToolSuggestions) {
|
|
326
|
-
lines.push(`**${s.
|
|
327
|
-
if (s.
|
|
338
|
+
lines.push(`**${s.toolName}**: ${s.reason}`);
|
|
339
|
+
if (Object.keys(s.args).length > 0) {
|
|
328
340
|
lines.push('```json');
|
|
329
|
-
lines.push(JSON.stringify(s.
|
|
341
|
+
lines.push(JSON.stringify(s.args, null, 2));
|
|
330
342
|
lines.push('```');
|
|
331
343
|
}
|
|
332
344
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pixoo-design-brief.tool.js","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-design-brief.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,eAAe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EAAE,CAAC,CAAC;YAC7C,IAAI,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;gBACnC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;gBACtB,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;gBAC5C,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YACpB,CAAC;QACH,CAAC;QACD,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACf,KAAK,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC;QAClC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;QAC9C,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACf,KAAK,CAAC,IAAI,CAAC,sBAAsB,CAAC,CAAC;QACnC,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,cAAc,CAAC,EAAE,CAAC;YACjE,KAAK,CAAC,IAAI,CAAC,KAAK,GAAG,OAAQ,KAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QAC9D,CAAC;QACD,OAAO,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpD,CAAC;CACF,CAAC,CAAC"}
|
|
@@ -75,6 +75,7 @@ export declare const pixooDisplayText: import("@cyanheads/mcp-ts-core").ToolDefi
|
|
|
75
75
|
brightness: z.ZodOptional<z.ZodNumber>;
|
|
76
76
|
}, z.core.$strip>, z.ZodObject<{
|
|
77
77
|
pushed: z.ZodBoolean;
|
|
78
|
+
frames: z.ZodNumber;
|
|
78
79
|
layout: z.ZodArray<z.ZodObject<{
|
|
79
80
|
element: z.ZodUnion<readonly [z.ZodNumber, z.ZodLiteral<"background">]>;
|
|
80
81
|
type: z.ZodString;
|
|
@@ -114,6 +115,12 @@ export declare const pixooDisplayText: import("@cyanheads/mcp-ts-core").ToolDefi
|
|
|
114
115
|
readonly retryable: true;
|
|
115
116
|
readonly recovery: "Check the device is powered on and on the same network. Retry in a few seconds.";
|
|
116
117
|
readonly thrownBy: "service";
|
|
118
|
+
}, {
|
|
119
|
+
readonly reason: "device_http_error";
|
|
120
|
+
readonly code: JsonRpcErrorCode.ServiceUnavailable;
|
|
121
|
+
readonly when: "The device answered with a non-2xx HTTP status (retryable for 408, 429, 500, and 502–504).";
|
|
122
|
+
readonly recovery: "The device may be busy or rebooting; wait a few seconds and retry. If it persists, run pixoo_discover_devices to confirm PIXOO_IP points at the Pixoo.";
|
|
123
|
+
readonly thrownBy: "service";
|
|
117
124
|
}, {
|
|
118
125
|
readonly reason: "device_rejected";
|
|
119
126
|
readonly code: JsonRpcErrorCode.ServiceUnavailable;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pixoo-display-text.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-display-text.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"pixoo-display-text.tool.d.ts","sourceRoot":"","sources":["../../../../src/mcp-server/tools/definitions/pixoo-display-text.tool.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAQ,CAAC,EAAE,MAAM,wBAAwB,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AAyIjE,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqa3B,CAAC"}
|